Skip to content

Commit f12ec97

Browse files
rix0rrrgithub-actionsmrgrain
authored
chore: allow patch bumping again on CLI package (#409)
Remove the previous short-term fix to prevent major version bumps, and replace it with the version filtering mechanism introduced in projen. --- By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license --------- Signed-off-by: github-actions <[email protected]> Co-authored-by: github-actions <[email protected]> Co-authored-by: Momo Kornher <[email protected]>
1 parent 8d91672 commit f12ec97

File tree

52 files changed

+90
-152
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+90
-152
lines changed

.projenrc.ts

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import * as path from 'path';
22
import { yarn } from 'cdklabs-projen-project-types';
3-
import type { TypeScriptWorkspaceOptions } from 'cdklabs-projen-project-types/lib/yarn';
3+
import { TypeScriptWorkspace, type TypeScriptWorkspaceOptions } from 'cdklabs-projen-project-types/lib/yarn';
44
import * as pj from 'projen';
55
import { Stability } from 'projen/lib/cdk';
66
import { AdcPublishing } from './projenrc/adc-publishing';
@@ -70,6 +70,11 @@ function configureProject<A extends pj.typescript.TypeScriptProject>(x: A): A {
7070
// Never include the build-tools directory
7171
x.npmignore?.addPatterns('build-tools');
7272

73+
if (x instanceof TypeScriptWorkspace) {
74+
// Individual workspace packages shouldn't depend on "projen", it gets brought in at the monorepo root
75+
x.deps.removeDependency('projen');
76+
}
77+
7378
return x;
7479
}
7580

@@ -667,7 +672,7 @@ const cdkAssets = configureProject(
667672
}),
668673

669674
// Append a specific version string for testing
670-
nextVersionCommand: 'tsx ../../projenrc/next-version.ts maybeRc',
675+
nextVersionCommand: 'tsx ../../projenrc/next-version.ts neverMajor maybeRc',
671676
}),
672677
);
673678

@@ -1268,13 +1273,7 @@ const cli = configureProject(
12681273
},
12691274
}),
12701275

1271-
// Append a specific version string for testing
1272-
// force a minor for the time being. This will never release a patch but that's fine for a while.
1273-
nextVersionCommand: 'tsx ../../projenrc/next-version.ts maybeRcOrMinor',
1274-
1275-
// re-enable this once we refactor the release tasks to prevent
1276-
// major version bumps caused by breaking commits in dependencies.
1277-
// nextVersionCommand: 'tsx ../../projenrc/next-version.ts maybeRc',
1276+
nextVersionCommand: 'tsx ../../projenrc/next-version.ts neverMajor maybeRc',
12781277

12791278
releasableCommits: transitiveToolkitPackages('aws-cdk'),
12801279
majorVersion: 2,

package.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/cli-integ/.projen/deps.json

Lines changed: 0 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/cli-integ/.projen/tasks.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/cli-integ/package.json

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk/cdk-cli-wrapper/.projen/deps.json

Lines changed: 0 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk/cdk-cli-wrapper/.projen/tasks.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk/cdk-cli-wrapper/package.json

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk/cli-lib-alpha/.projen/deps.json

Lines changed: 0 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk/cli-lib-alpha/.projen/tasks.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)