Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(cli): control library init version with a command-line parameter #149

Merged
merged 5 commits into from
Feb 27, 2025

Conversation

rix0rrr
Copy link
Contributor

@rix0rrr rix0rrr commented Feb 25, 2025

Allows controlling of the cdk init version of aws-cdk-lib:

cdk init --lib-version=1.2.3 

Mainly intended to be used by tests (to smoke-test that upcoming library versions still init properly), but it can be used by users as well.


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

Allows controlling of the `cdk init` version of `aws-cdk-lib` using an
environment variable. This will be used by tests.
@rix0rrr rix0rrr requested a review from a team February 25, 2025 15:13
@codecov-commenter
Copy link

codecov-commenter commented Feb 25, 2025

Codecov Report

Attention: Patch coverage is 60.00000% with 10 lines in your changes missing coverage. Please review.

Project coverage is 84.53%. Comparing base (5b3afbe) to head (3b85471).

Files with missing lines Patch % Lines
...es/aws-cdk/lib/cli/parse-command-line-arguments.ts 0.00% 6 Missing ⚠️
packages/aws-cdk/lib/cli/convert-to-user-input.ts 0.00% 2 Missing ⚠️
packages/aws-cdk/lib/cli/cli.ts 0.00% 1 Missing ⚠️
packages/aws-cdk/lib/init.ts 93.75% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #149      +/-   ##
==========================================
- Coverage   84.80%   84.53%   -0.27%     
==========================================
  Files         198      198              
  Lines       35380    35400      +20     
  Branches     4572     4542      -30     
==========================================
- Hits        30003    29926      -77     
- Misses       5232     5329      +97     
  Partials      145      145              
Flag Coverage Δ
suite.unit 84.53% <60.00%> (-0.27%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@mrgrain mrgrain left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we just make this a cli feature? E.g. cdk init app --l typescript --version 2.123.0

@rix0rrr
Copy link
Contributor Author

rix0rrr commented Feb 27, 2025

Should we just make this a cli feature

Fair! Yeah, why not

@rix0rrr rix0rrr changed the title feat(cli): control init version with an environment variable feat(cli): control library init version with a command-line parameter Feb 27, 2025
@mrgrain mrgrain disabled auto-merge February 27, 2025 09:58
Signed-off-by: github-actions <[email protected]>
@rix0rrr rix0rrr added the pr/exempt-integ-test Skips the integ test steps if set. label Feb 27, 2025
@mrgrain mrgrain added this pull request to the merge queue Feb 27, 2025
Merged via the queue into main with commit f925551 Feb 27, 2025
11 checks passed
@mrgrain mrgrain deleted the huijbers/init-env branch February 27, 2025 13:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr/exempt-integ-test Skips the integ test steps if set.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants