-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Using "--amend" and "--message" options will not overwrite the original commit message #3936
Comments
Why do you have to push two times? I think one push in the end with the correct message will be sufficient. This push you have to do anyway as amend will not push. |
First push is to use lerna to increment packages + publish them; it also amends a squashed commit so that all changes are kept in a single commit instead of two. The second push is to change the original commit message to a custom chore message using the version change made in the first push. We've tried it many other ways, and while it's not pretty, it functions how it is expected. |
Current Behavior
When using
--amend
and--message
, the commit will be amended but the message will remain unchanged. The--message
option is not respected and will be implicitly ignored.Examples:
lerna version minor --amend --message "My commit message"
lerna version publish minor --amend --message "My commit message"
Expected Behavior
--message
The code below will accomplish everything above, but is not recommended due to pushing remote references twice:
Steps to Reproduce
lerna publish minor --amend --exact --message "This is a new commit message" --yes
This issue may not be prioritized if details are not provided to help us reproduce the issue.
Failure Logs / Configuration
lerna.json
Environment
npx lerna info
:The text was updated successfully, but these errors were encountered: