Skip to content

Commit

Permalink
add safe directory step to lint steps #324
Browse files Browse the repository at this point in the history
  • Loading branch information
jazzyfresh committed Feb 8, 2023
1 parent 51031fc commit 3ee27e5
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
7 changes: 7 additions & 0 deletions provider-ci/src/steps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,13 @@ export function CheckoutScriptsRepoStep(): Step {
};
}

export function CheckoutSafeDirectoryStep(): Step {
return {
name: "Mark repo as safe directory",
run: "git config --global --add safe.directory /__w/pulumi-${{ env.PROVIDER }}/pulumi-${{ env.PROVIDER }}",
};
}

export function CheckoutTagsStep(): Step {
return {
name: "Unshallow clone for tags",
Expand Down
2 changes: 2 additions & 0 deletions provider-ci/src/workflows.ts
Original file line number Diff line number Diff line change
Expand Up @@ -901,6 +901,7 @@ export class LintProviderJob implements NormalJob {
steps = [
steps.CheckoutRepoStep(),
steps.CheckoutScriptsRepoStep(),
steps.CheckoutSafeDirectoryStep(),
steps.CheckoutTagsStep(),
steps.InstallGo(),
steps.InstallPulumiCtl(),
Expand Down Expand Up @@ -944,6 +945,7 @@ export class LintSDKJob implements NormalJob {
this.steps = [
steps.CheckoutRepoStep(),
steps.CheckoutScriptsRepoStep(),
steps.CheckoutSafeDirectoryStep(),
steps.CheckoutTagsStep(),
steps.InstallGo(),
steps.InstallPulumiCtl(),
Expand Down

0 comments on commit 3ee27e5

Please sign in to comment.