-
Notifications
You must be signed in to change notification settings - Fork 4k
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
chore(scripts): allow --reset --up/--down to automatically run script #8826
Conversation
@nija-at @njlynch I saw both #8782 and #8784 and the comments on how buildup and builddown is just to be used as an alias for building. However, I quite liked the previous implementation of I think our customers contributing to our codebase might find a benefit in simple to use commands that reduce their workflow! Open to suggestions though and if this is something that we want to be pushed to production, I can briefly append to the README. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @BryanPan342 -
Thanks for submitting this PR 😊
It seems that the functionality you're looking for already exists. You could run the same thing using foreach.sh --down yarn <command>
. It feels better to keep buildup
and builddown
for the most simple case and use foreach.sh
for anything more advanced.
A better contribution/improvement would be in the foreach
script instead. foreach
needs to be explicitly reset each time by the user. It could be helpful to reset the state when it completes processing the tree successfully. Additionally, a -f
or a --force
option could be added to reset the state if the user intends to discard previous state regardless of how far it has executed through the tree.
This way, foreach
can be executed in a single step, similar to buildup
and builddown
.
Okay yeah this makes a lot of sense. I think the natural format to tackle this for me:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't forget to update the PR title and description to the new changes 😊
Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
…aws#8826) **[ISSUE]** Honestly, kind of miss being able to use `lerna` for any kind of npm test through parameters with the old `builddown`. Wanted to be able to run something like `builddown build+test` or `builddown test`. **[APPROACH]** Added a `-r | --reset` flag to allow the `foreach.sh` script to reset and run in one line like `builddown`/`buildup`. **[NOTE]** Won't change anyone's current workflow because `--reset` is still in codebase. Also arguments for the script aren't restricted by order (i.e. `foreach.sh --reset --up yarn build ` and `builddown yarn build --up --reset` will produce the same results)! ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
[ISSUE]
Honestly, kind of miss being able to use
lerna
for any kind of npm test through parameters with the oldbuilddown
. Wanted to be able to run something likebuilddown build+test
orbuilddown test
.[APPROACH]
Added a
-r | --reset
flag to allow theforeach.sh
script to reset and run in one line likebuilddown
/buildup
.[NOTE]
Won't change anyone's current workflow because
--reset
is still in codebase.Also arguments for the script aren't restricted by order (i.e.
foreach.sh --reset --up yarn build
andbuilddown yarn build --up --reset
will produce the same results)!By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license