Skip to content

Commit

Permalink
chore: disable required CLA checks (#282)
Browse files Browse the repository at this point in the history
  • Loading branch information
xiehan authored Apr 2, 2024
1 parent 9f952e0 commit c6606f6
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 11 deletions.
20 changes: 11 additions & 9 deletions lib/repository.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ export class RepositorySetup extends Construct {

const {
protectMain = false,
protectMainChecks = ["build", "license/cla"],
// @TODO: uncomment the below line if we want to require CLA checks again (and remove the line below it)
// protectMainChecks = ["build", "license/cla"],
protectMainChecks = ["build"],
provider,
repository,
team,
Expand All @@ -61,7 +63,7 @@ export class RepositorySetup extends Construct {
name: "no-auto-close",
repository: repository.name,
provider,
}),
});

new IssueLabel(this, `auto-approve-label`, {
color: "8BF8BD",
Expand All @@ -85,14 +87,15 @@ export class RepositorySetup extends Construct {
},
],
requireConversationResolution: true,
requiredLinearHistory: true,
requiredStatusChecks: [
{
strict: true,
strict: false,
contexts: protectMainChecks,
},
],
provider,
})
});
}

new TeamRepository(this, "managing-team", {
Expand All @@ -111,11 +114,10 @@ export class RepositorySetup extends Construct {
contentType: "json",
},

// We don't need to notify about PRs since they are auto-created
events: ["issues"],
provider,
});

// We don't need to notify about PRs since they are auto-created
events: ["issues"],
provider,
});
}
}

Expand Down
6 changes: 4 additions & 2 deletions main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,9 @@ class CustomConstructsStack extends TerraformStack {
const secrets = new PublishingSecretSet(this, "secret-set");

constructRepos.forEach(({ name: repoName, languages, topics }) => {
const protectMainChecks = ["build", "license/cla"].concat(
// @TODO: uncomment the below line if we want to require CLA checks again (and remove the line below it)
// const protectMainChecks = ["build", "license/cla"].concat(
const protectMainChecks = ["build"].concat(
languages.map((language) => {
return `package-${
language === "typescript"
Expand Down Expand Up @@ -376,7 +378,7 @@ stackNames.forEach((stackName) => {
const providerStack = new TerraformCdkProviderStack(
app,
stackName,
primaryStackName === stackName
primaryStackName === stackName,
);
Aspects.of(providerStack).add(new MigrateIds());
});
Expand Down

0 comments on commit c6606f6

Please sign in to comment.