GitLab cancel or delete a push
Asked Answered
F

1

6

I want to cancel my last push, because a pushed the app/build folder changes Is it possible to revert a push or the last push in Gitlab?

Fifth answered 23/5, 2016 at 12:1 Comment(3)
Thanks for your constructif answer.Fifth
Do a hard reset to the previous commit....?Vagus
Yes, I tried I hard reset and I pushed it on GitLab, and it works Thanks.Fifth
A
8

Either you can delete the commit locally and use force push or create a revert commit via GitLab UI (GitLab 8.5 or newer):

Select your commit in the history you want to revert and click on the revert button:

enter image description here

There will be a modal dialog. You can choice if you want to create a Merge Request or directly commit it to the default branch:

enter image description here

More details

Apophyllite answered 24/5, 2016 at 15:56 Comment(4)
Thanks a lot CSchulz, but I am on the 8.0.5 version, I suppose i can't see the revert option.Fifth
But I found an other way, by a hard rest.Fifth
In this case you have done the same as described in the linked answer.Apophyllite
By this way the wrong commit remains in the history. Is there any way to erase it as it never happened?Roemer

© 2022 - 2024 — McMap. All rights reserved.