aws / aws-toolkit-vscode

Amazon Q, CodeCatalyst, Local Lambda debug, SAM/CFN syntax, ECS Terminal, AWS resources
https://marketplace.visualstudio.com/items?itemName=AmazonWebServices.amazon-q-vscode
Apache License 2.0
1.41k stars 346 forks source link

fix(ci): feature branch name missing from toolkit artifact #5222

Closed justinmk3 closed 1 week ago

justinmk3 commented 1 week ago

Problem:

Because of the npm run restorePackageJson step, the --feature separate-sessions arg is not passed to package.ts:

npm run copyPackageJson && ts-node ../../scripts/package.ts && npm run restorePackageJson --feature separate-sessions

Thus the feature branch name is not in the toolkit artifact name. For example, the feature/separate-sessions branch artifacts are:

amazon-q-vscode-1.10.0-separate-sessions-g8a563a7.vsix
aws-toolkit-vscode-3.11.0-g8a563a7.vsix

Solution:

Inline the --restore logic into package.ts. This is hacky, but should be temporary after we resolved IDE-12831 so that these hacks are no longer needed.

Example

https://github.com/justinmk3/aws-toolkit-vscode/releases/tag/pre-smurf

License

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.