Skip to content

Commit

Permalink
Disable sourceVersion when disableSourceOverride is set
Browse files Browse the repository at this point in the history
  • Loading branch information
marcus-bcl committed Sep 22, 2022
1 parent 47793a1 commit 0487e20
Show file tree
Hide file tree
Showing 4 changed files with 59,017 additions and 291,439 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ we always pass the following parameters and values to CodeBuild in the StartBuil
| `sourceTypeOverride` | The string `'GITHUB'` |
| `sourceLocationOverride` | The `HTTPS` git url for `context.repo` |
If you want to disable sending the parameters `sourceTypeOverride` and `sourceLocationOverride` you can use `disable-source-override` input.
If you want to disable sending the parameters `sourceVersion`, `sourceTypeOverride` and `sourceLocationOverride` you can use `disable-source-override` input.
### What we did not do
Expand Down
2 changes: 1 addition & 1 deletion code-build.js
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,7 @@ function inputs2Parameters(inputs) {

const sourceOverride = !disableSourceOverride
? {
sourceVersion: sourceVersion,
sourceTypeOverride: "GITHUB",
sourceLocationOverride: `https://github.com/${owner}/${repo}.git`,
}
Expand All @@ -230,7 +231,6 @@ function inputs2Parameters(inputs) {
// This way the GitHub events can manage the builds.
return {
projectName,
sourceVersion,
...sourceOverride,
buildspecOverride,
computeTypeOverride,
Expand Down
Loading

0 comments on commit 0487e20

Please sign in to comment.