diff --git a/docs/nx-cloud/set-up/set-up-dte.md b/docs/nx-cloud/set-up/set-up-dte.md index 27fdb079f3..5da90bd2e4 100644 --- a/docs/nx-cloud/set-up/set-up-dte.md +++ b/docs/nx-cloud/set-up/set-up-dte.md @@ -15,9 +15,7 @@ The main job execution flow looks like this: # Coordinate the agents to run the tasks - npx nx-cloud start-ci-run # Run any commands you want here -- nx affected --target=lint -- nx affected --target=test -- nx affected --target=build +- nx affected --target=lint & nx affected --target=test & nx affected --target=build # Stop any run away agents - npx nx-cloud stop-all-agents ``` diff --git a/docs/shared/core-features/distribute-task-execution.md b/docs/shared/core-features/distribute-task-execution.md index 3bd6cdb43f..eadcd1d136 100644 --- a/docs/shared/core-features/distribute-task-execution.md +++ b/docs/shared/core-features/distribute-task-execution.md @@ -41,9 +41,7 @@ The main job execution flow looks like this: # Coordinate the agents to run the tasks - npx nx-cloud start-ci-run # Run any commands you want here -- nx affected --target=lint -- nx affected --target=test -- nx affected --target=build +- nx affected --target=lint & nx affected --target=test & nx affected --target=build # Stop any run away agents - npx nx-cloud stop-all-agents ``` diff --git a/docs/shared/monorepo-ci-azure.md b/docs/shared/monorepo-ci-azure.md index f3e608d1bd..8bd48aeca2 100644 --- a/docs/shared/monorepo-ci-azure.md +++ b/docs/shared/monorepo-ci-azure.md @@ -86,9 +86,7 @@ jobs: - script: npx nx-cloud record -- npx nx workspace-lint - script: npx nx-cloud record -- npx nx format:check --base=$(BASE_SHA) --head=$(HEAD_SHA) - - script: npx nx affected --base=$(BASE_SHA) --head=$(HEAD_SHA) --target=lint --parallel=3 - - script: npx nx affected --base=$(BASE_SHA) --head=$(HEAD_SHA) --target=test --parallel=3 --ci --code-coverage - - script: npx nx affected --base=$(BASE_SHA) --head=$(HEAD_SHA) --target=build --parallel=3 + - script: npx nx affected --base=$(BASE_SHA) --head=$(HEAD_SHA) --target=lint --parallel=3 & npx nx affected --base=$(BASE_SHA) --head=$(HEAD_SHA) --target=test --parallel=3 --ci --code-coverage & npx nx affected --base=$(BASE_SHA) --head=$(HEAD_SHA) --target=build --parallel=3 ``` You can also use our [ci-workflow generator](/packages/workspace/generators/ci-workflow) to generate the pipeline file. diff --git a/docs/shared/monorepo-ci-bitbucket-pipelines.md b/docs/shared/monorepo-ci-bitbucket-pipelines.md index ebe93c1f23..0da68539c8 100644 --- a/docs/shared/monorepo-ci-bitbucket-pipelines.md +++ b/docs/shared/monorepo-ci-bitbucket-pipelines.md @@ -29,9 +29,7 @@ pipelines: - npm ci - npx nx workspace-lint - npx nx format:check - - npx nx affected --target=lint --base=origin/master --parallel --max-parallel=3 - - npx nx affected --target=test --base=HEAD~1 --parallel --max-parallel=3 --ci --code-coverage - - npx nx affected --target=build --base=HEAD~1 --parallel --max-parallel=3 + - npx nx affected --target=lint --base=origin/master --parallel --max-parallel=3 & npx nx affected --target=test --base=HEAD~1 --parallel --max-parallel=3 --ci --code-coverage & npx nx affected --target=build --base=HEAD~1 --parallel --max-parallel=3 ``` The `pull-requests` and `main` jobs implement the CI workflow. diff --git a/docs/shared/monorepo-ci-circle-ci.md b/docs/shared/monorepo-ci-circle-ci.md index 36e666f255..a2346ed470 100644 --- a/docs/shared/monorepo-ci-circle-ci.md +++ b/docs/shared/monorepo-ci-circle-ci.md @@ -75,9 +75,7 @@ jobs: - run: npx nx-cloud record -- npx nx workspace-lint - run: npx nx-cloud record -- npx nx format:check - - run: npx nx affected --base=$NX_BASE --head=$NX_HEAD --target=lint --parallel=3 - - run: npx nx affected --base=$NX_BASE --head=$NX_HEAD --target=test --parallel=3 --ci --code-coverage - - run: npx nx affected --base=$NX_BASE --head=$NX_HEAD --target=build --parallel=3 + - run: npx nx affected --base=$NX_BASE --head=$NX_HEAD --target=lint --parallel=3 & npx nx affected --base=$NX_BASE --head=$NX_HEAD --target=test --parallel=3 --ci --code-coverage & npx nx affected --base=$NX_BASE --head=$NX_HEAD --target=build --parallel=3 workflows: build: jobs: diff --git a/docs/shared/monorepo-ci-github-actions.md b/docs/shared/monorepo-ci-github-actions.md index 1c0c728248..4d0620a020 100644 --- a/docs/shared/monorepo-ci-github-actions.md +++ b/docs/shared/monorepo-ci-github-actions.md @@ -58,9 +58,7 @@ jobs: npx nx-cloud record -- npx nx workspace-lint npx nx-cloud record -- npx nx format:check parallel-commands-on-agents: | - npx nx affected --target=lint --parallel=3 - npx nx affected --target=test --parallel=3 --ci --code-coverage - npx nx affected --target=build --parallel=3 + npx nx affected --target=lint --parallel=3 & npx nx affected --target=test --parallel=3 --ci --code-coverage & npx nx affected --target=build --parallel=3 agents: name: Nx Cloud - Agents diff --git a/docs/shared/monorepo-ci-gitlab.md b/docs/shared/monorepo-ci-gitlab.md index c5f354ad82..93c5f8fc39 100644 --- a/docs/shared/monorepo-ci-gitlab.md +++ b/docs/shared/monorepo-ci-gitlab.md @@ -120,10 +120,7 @@ nx-dte: - yarn nx-cloud start-ci-run --stop-agents-after="build" - yarn nx-cloud record -- yarn nx workspace-lint --base=$NX_BASE --head=$NX_HEAD - yarn nx-cloud record -- yarn nx format:check --base=$NX_BASE --head=$NX_HEAD - - yarn nx affected --base=$NX_BASE --head=$NX_HEAD --target=lint --parallel=3 - - yarn nx affected --base=$NX_BASE --head=$NX_HEAD --target=test --parallel=3 --ci --code-coverage - - yarn nx affected --base=$NX_BASE --head=$NX_HEAD --target=e2e --parallel=3 --ci --code-coverage - - yarn nx affected --base=$NX_BASE --head=$NX_HEAD --target=build --parallel=3 + - yarn nx affected --base=$NX_BASE --head=$NX_HEAD --target=lint --parallel=3 & yarn nx affected --base=$NX_BASE --head=$NX_HEAD --target=test --parallel=3 --ci --code-coverage & yarn nx affected --base=$NX_BASE --head=$NX_HEAD --target=e2e --parallel=3 --ci --code-coverage & yarn nx affected --base=$NX_BASE --head=$NX_HEAD --target=build --parallel=3 # Create as many agents as you want nx-dte-agent1: diff --git a/docs/shared/monorepo-ci-jenkins.md b/docs/shared/monorepo-ci-jenkins.md index 8f5627c63a..b0f9cb2d8a 100644 --- a/docs/shared/monorepo-ci-jenkins.md +++ b/docs/shared/monorepo-ci-jenkins.md @@ -78,9 +78,7 @@ pipeline { sh "npx nx-cloud start-ci-run --stop-agents-after='build'" sh "npx nx workspace-lint" sh "npx nx format:check" - sh "npx nx affected --base=HEAD~1 --target=lint --parallel=3" - sh "npx nx affected --base=HEAD~1 --target=test --parallel=3 --ci --code-coverage" - sh "npx nx affected --base=HEAD~1 --target=build --parallel=3" + sh "npx nx affected --base=HEAD~1 --target=lint --parallel=3 & npx nx affected --base=HEAD~1 --target=test --parallel=3 --ci --code-coverage & npx nx affected --base=HEAD~1 --target=build --parallel=3" } } stage('PR') { @@ -93,9 +91,7 @@ pipeline { sh "npx nx-cloud start-ci-run --stop-agents-after='build'" sh "npx nx workspace-lint" sh "npx nx format:check" - sh "npx nx affected --base origin/${env.CHANGE_TARGET} --target=lint --parallel=3" - sh "npx nx affected --base origin/${env.CHANGE_TARGET} --target=test --parallel=3 --ci --code-coverage" - sh "npx nx affected --base origin/${env.CHANGE_TARGET} --target=build --parallel=3" + sh "npx nx affected --base origin/${env.CHANGE_TARGET} --target=lint --parallel=3 & npx nx affected --base origin/${env.CHANGE_TARGET} --target=test --parallel=3 --ci --code-coverage & npx nx affected --base origin/${env.CHANGE_TARGET} --target=build --parallel=3" } }