Skip to content

Commit

Permalink
Merge pull request #3949 from chengcyber/feat-cobuild
Browse files Browse the repository at this point in the history
[rush] Implementation of Cobuild feature
  • Loading branch information
iclanton committed Sep 1, 2023
2 parents 1ef2801 + fac1898 commit e75d61a
Show file tree
Hide file tree
Showing 125 changed files with 9,618 additions and 3,642 deletions.
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,14 @@ jspm_packages/
.idea/
*.iml

# Visual Studio Code
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
!*.code-workspace

# Rush temporary files
common/deploy/
common/temp/
Expand Down
3 changes: 3 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,9 @@ libraries/rush-lib/assets/rush-init/
# These are intentionally invalid files
libraries/heft-config-file/src/test/errorCases/invalidJson/config.json

# common scripts in sandbox repo
build-tests/rush-redis-cobuild-plugin-integration-test/sandbox/repo/common/scripts/

# We'll consider enabling this later; Prettier reformats code blocks, which affects end-user content
*.md

Expand Down
20 changes: 20 additions & 0 deletions .vscode/redis-cobuild.code-workspace
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"folders": [
{
"name": "rush-redis-cobuild-plugin-integration-test",
"path": "../build-tests/rush-redis-cobuild-plugin-integration-test"
},
{
"name": "rush-redis-cobuild-plugin",
"path": "../rush-plugins/rush-redis-cobuild-plugin"
},
{
"name": "rush-lib",
"path": "../libraries/rush-lib"
},
{
"name": ".vscode",
"path": "../.vscode"
}
]
}
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ These GitHub repositories provide supplementary resources for Rush Stack:
| [/rush-plugins/rush-amazon-s3-build-cache-plugin](./rush-plugins/rush-amazon-s3-build-cache-plugin/) | [![npm version](https://badge.fury.io/js/%40rushstack%2Frush-amazon-s3-build-cache-plugin.svg)](https://badge.fury.io/js/%40rushstack%2Frush-amazon-s3-build-cache-plugin) | | [@rushstack/rush-amazon-s3-build-cache-plugin](https://www.npmjs.com/package/@rushstack/rush-amazon-s3-build-cache-plugin) |
| [/rush-plugins/rush-azure-storage-build-cache-plugin](./rush-plugins/rush-azure-storage-build-cache-plugin/) | [![npm version](https://badge.fury.io/js/%40rushstack%2Frush-azure-storage-build-cache-plugin.svg)](https://badge.fury.io/js/%40rushstack%2Frush-azure-storage-build-cache-plugin) | | [@rushstack/rush-azure-storage-build-cache-plugin](https://www.npmjs.com/package/@rushstack/rush-azure-storage-build-cache-plugin) |
| [/rush-plugins/rush-http-build-cache-plugin](./rush-plugins/rush-http-build-cache-plugin/) | [![npm version](https://badge.fury.io/js/%40rushstack%2Frush-http-build-cache-plugin.svg)](https://badge.fury.io/js/%40rushstack%2Frush-http-build-cache-plugin) | | [@rushstack/rush-http-build-cache-plugin](https://www.npmjs.com/package/@rushstack/rush-http-build-cache-plugin) |
| [/rush-plugins/rush-redis-cobuild-plugin](./rush-plugins/rush-redis-cobuild-plugin/) | [![npm version](https://badge.fury.io/js/%40rushstack%2Frush-redis-cobuild-plugin.svg)](https://badge.fury.io/js/%40rushstack%2Frush-redis-cobuild-plugin) | | [@rushstack/rush-redis-cobuild-plugin](https://www.npmjs.com/package/@rushstack/rush-redis-cobuild-plugin) |
| [/rush-plugins/rush-serve-plugin](./rush-plugins/rush-serve-plugin/) | [![npm version](https://badge.fury.io/js/%40rushstack%2Frush-serve-plugin.svg)](https://badge.fury.io/js/%40rushstack%2Frush-serve-plugin) | | [@rushstack/rush-serve-plugin](https://www.npmjs.com/package/@rushstack/rush-serve-plugin) |
| [/webpack/hashed-folder-copy-plugin](./webpack/hashed-folder-copy-plugin/) | [![npm version](https://badge.fury.io/js/%40rushstack%2Fhashed-folder-copy-plugin.svg)](https://badge.fury.io/js/%40rushstack%2Fhashed-folder-copy-plugin) | [changelog](./webpack/hashed-folder-copy-plugin/CHANGELOG.md) | [@rushstack/hashed-folder-copy-plugin](https://www.npmjs.com/package/@rushstack/hashed-folder-copy-plugin) |
| [/webpack/loader-load-themed-styles](./webpack/loader-load-themed-styles/) | [![npm version](https://badge.fury.io/js/%40microsoft%2Floader-load-themed-styles.svg)](https://badge.fury.io/js/%40microsoft%2Floader-load-themed-styles) | [changelog](./webpack/loader-load-themed-styles/CHANGELOG.md) | [@microsoft/loader-load-themed-styles](https://www.npmjs.com/package/@microsoft/loader-load-themed-styles) |
Expand Down Expand Up @@ -169,6 +170,7 @@ These GitHub repositories provide supplementary resources for Rush Stack:
| [/build-tests/rush-amazon-s3-build-cache-plugin-integration-test](./build-tests/rush-amazon-s3-build-cache-plugin-integration-test/) | Tests connecting to an amazon S3 endpoint |
| [/build-tests/rush-lib-declaration-paths-test](./build-tests/rush-lib-declaration-paths-test/) | This project ensures all of the paths in rush-lib/lib/... have imports that resolve correctly. If this project builds, all `lib/**/*.d.ts` files in the `@microsoft/rush-lib` package are valid. |
| [/build-tests/rush-project-change-analyzer-test](./build-tests/rush-project-change-analyzer-test/) | This is an example project that uses rush-lib's ProjectChangeAnalyzer to |
| [/build-tests/rush-redis-cobuild-plugin-integration-test](./build-tests/rush-redis-cobuild-plugin-integration-test/) | Tests connecting to an redis server |
| [/build-tests/set-webpack-public-path-plugin-webpack4-test](./build-tests/set-webpack-public-path-plugin-webpack4-test/) | Building this project tests the set-webpack-public-path-plugin using Webpack 4 |
| [/build-tests/ts-command-line-test](./build-tests/ts-command-line-test/) | Building this project is a regression test for ts-command-line |
| [/libraries/rush-themed-ui](./libraries/rush-themed-ui/) | Rush Component Library: a set of themed components for rush projects |
Expand Down
68 changes: 37 additions & 31 deletions build-tests/install-test-workspace/workspace/common/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/node'],
parserOptions: { tsconfigRootDir: __dirname }
};
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
redis-data/dump.rdb
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
{
"version": "2.0.0",
"tasks": [
{
"type": "shell",
"label": "cobuild",
"dependsOrder": "sequence",
"dependsOn": ["update", "_cobuild"],
"problemMatcher": []
},
{
"type": "shell",
"label": "_cobuild",
"dependsOn": ["build 1", "build 2"],
"problemMatcher": []
},
{
"type": "shell",
"label": "update",
"command": "node ../../lib/runRush.js update",
"problemMatcher": [],
"presentation": {
"echo": true,
"reveal": "always",
"focus": false,
"panel": "dedicated",
"showReuseMessage": true,
"clear": false
},
"options": {
"cwd": "${workspaceFolder}/sandbox/repo"
}
},
{
"type": "shell",
"label": "build 1",
"command": "node ../../lib/runRush.js --debug cobuild --timeline --parallelism 1 --verbose",
"problemMatcher": [],
"options": {
"cwd": "${workspaceFolder}/sandbox/repo",
"env": {
"RUSH_COBUILD_CONTEXT_ID": "integration-test",
"RUSH_COBUILD_RUNNER_ID": "runner1",
"RUSH_COBUILD_LEAF_PROJECT_LOG_ONLY_ALLOWED": "1",
"REDIS_PASS": "redis123"
}
},
"presentation": {
"echo": true,
"reveal": "always",
"focus": false,
"panel": "dedicated",
"showReuseMessage": true,
"clear": true
},
"group": "build"
},
{
"type": "shell",
"label": "build 2",
"command": "node ../../lib/runRush.js --debug cobuild --timeline --parallelism 1 --verbose",
"problemMatcher": [],
"options": {
"cwd": "${workspaceFolder}/sandbox/repo",
"env": {
"RUSH_COBUILD_CONTEXT_ID": "integration-test",
"RUSH_COBUILD_RUNNER_ID": "runner2",
"RUSH_COBUILD_LEAF_PROJECT_LOG_ONLY_ALLOWED": "1",
"REDIS_PASS": "redis123"
}
},
"presentation": {
"echo": true,
"reveal": "always",
"focus": false,
"panel": "dedicated",
"showReuseMessage": true,
"clear": true
},
"group": "build"
}
]
}
Loading

0 comments on commit e75d61a

Please sign in to comment.