Include `!**/lambda/*.js` in `.gitignore` by default
zachgoll opened this issue · 2 comments
General Information
- I may be able to implement this feature request
- This feature might incur a breaking change
Description
While going through the CDK Pipelines portion of the workshop, if you have not updated the .gitignore
file, your pipeline will fail because the lambda assets will not be discoverable from the build output:
When initially creating the lambda function, the tutorial mentions, "Also, if you are going to actively use git, consider adding !lambda/*.js in .gitignore file." (source)
I think it would be a nice default to not ignore the lambda code as it breaks the remainder of the workshop and is pretty easy to miss.
Proposed Solution
I think there are 2 possible improvements:
- Include the line
!**/lambda/*.js
in the.gitignore
by default - even if the user does not follow the CDK Pipelines portion of the tutorial, this doesn't hurt to have in there. - Or... Update this page to be more descriptive as to why you need to add this snippet (when I first read through, I totally missed that the
.gitignore
by default ignored JS files). Proposed below:
Overall, very small changes, but would have saved me a couple hours and I think it could do the same for future viewers of this tutorial!
CDK CLI Version
2.21.1
Section
CDK Pipelines
Browser
Chrome
Language
TypeScript
Other information
No response
but it's only required in ts because only that will ignore js files by default