Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/workflows/pull-request-lint.yml

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

35 changes: 21 additions & 14 deletions .projenrc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -232,20 +232,7 @@ const repoProject = new yarn.Monorepo({
},
semanticTitleOptions: {
types: ['feat', 'fix', 'chore', 'refactor', 'test', 'docs', 'revert'],
scopes: [
'cdk-assets',
'cli',
'cli-lib-alpha',
'cli-plugin-contract',
'cloud-assembly-schema',
'cloudformation-diff',
'deps',
'dev-deps',
'docs',
'integ-runner',
'integ-testing',
'toolkit-lib',
],
scopes: [], // actually set at the bottom of the file to be based on monorepo packages
},
},
},
Expand Down Expand Up @@ -1736,4 +1723,24 @@ new LargePrChecker(repo, {

((repo.github?.tryFindWorkflow('integ')?.getJob('prepare') as Job | undefined)?.env ?? {}).DEBUG = 'true';

// Set allowed scopes based on monorepo packages
const disallowed = new Set([
'cdk', // use aws-cdk or cli
'user-input-gen', // use cli
]);
repoProject.github?.tryFindWorkflow('pull-request-lint')?.file?.patch(
pj.JsonPatch.replace('/jobs/validate/steps/0/with/scopes', [
'cli',
'deps',
'dev-deps',
'docs',
'integ-testing',
'toolkit-lib',
...repoProject.subprojects
.filter(p => p instanceof yarn.TypeScriptWorkspace)
.map(p => p.name)
.map(n => n.split('/').pop()),
].filter(s => s && !disallowed.has(s)).sort().join('\n')),
);

repo.synth();
Loading