-
-
Notifications
You must be signed in to change notification settings - Fork 300
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
Rollback Git operations when publish fails and on termination #334
Rollback Git operations when publish fails and on termination #334
Conversation
When publish fails it doesn't rollback:
It's weird that |
I noticed this as well, but haven't figured out why it happens yet. I'll dive into the issue later today. |
@sindresorhus aae3a7e should fix some of the issues you were talking about. |
Let me know when #334 (comment) is fixed. |
@sindresorhus It is fixed. The current issue is that when terminating |
@sindresorhus The origin of the issue was that I used |
@sindresorhus Do you think we should add a note about this to the readme? (probably in the |
Add a note about what? |
The fact the |
It doesn't seem to work when the publish command fails. Just for testing I changed the actual command from
It says it rolled back the state, but I still have the |
Yes, definitely. Should also be mentioned in the highlights as it's a good feature. |
Fixed in 0ed1047. |
@sindresorhus I think that this is ready to be merged. @NeekSandhu @SamVerschueren It would be great if you could test this out and let me know if this works for you as expected. |
It's working well for me :) |
Found another issue. It shows the rollback message when a running the tests and a test fails. However, it's not technically rolling back anything then as nothing has been committed yet.
|
@sindresorhus I opened an issue to track this: #396. |
This is my first attempt at fixing #197. The code's not really working for some reason, and I'm pushing this to get an initial review since I've been trying to get this to work for nearly two weeks.
Fixes #197