On Sat, Dec 21, 2019 at 9:44 PM Antonio Trande <anto.tra...@gmail.com> wrote: > > > > On 21/12/19 21:38, Fabio Valentini wrote: > > On Sat, Dec 21, 2019 at 9:30 PM Antonio Trande <anto.tra...@gmail.com> > > wrote: > >> > >> On 21/12/19 21:19, Fabio Valentini wrote: > >>> On Sat, Dec 21, 2019 at 9:11 PM Antonio Trande <anto.tra...@gmail.com> > >>> wrote: > >>>> > >>>> Hi all. > >>>> > >>>> Please, can you help me to remove this last commit on EPEL7 branch? > >>>> > >>>> https://src.fedoraproject.org/rpms/petsc4py/c/e47fbb3ef419b7be939108c2b1deff3f105bfdbc?branch=epel7 > >>>> > >>>> (I wish top return to the 3.11.0 release of petsc4py) > >>> > >>> git commits cannot be removed from dist-git. > >>> If you have not built this commit for EPEL7, then reverting the > >>> unwanted commits and pushing the result should do what you want? > >>> (I see that this is a merge commit, and I don't know how smart git is > >>> with reverting merge commits. You'll have to try to see it, I guess.) > >>> > >>> Fabio > >>> > >> > >> Hi Fabio. > >> > >> $ fedpkg switch-branch epel7 > >> Branch 'epel7' set up to track remote branch 'epel7' from 'origin'. > > > > <snip> > > > >> $ git reset --hard cf25d6d376fc95034decec02c2e1501f97ae4955 > >> HEAD is now at cf25d6d Rebuild for PETSc-3.11.3 > >> > >> $ git commit -am "Undo latest commit" > >> On branch epel7 > >> Your branch is behind 'origin/epel7' by 6 commits, and can be > >> fast-forwarded. > >> (use "git pull" to update your local branch) > >> > >> nothing to commit, working tree clean > > > > That's why I wrote "revert" and not "reset". > > Because it failed: > > $ fedpkg switch-branch epel7 > Branch 'epel7' set up to track remote branch 'epel7' from 'origin'. > $ git revert cf25d6d376fc95034decec02c2e1501f97ae4955 > error: commit cf25d6d376fc95034decec02c2e1501f97ae4955 is a merge but no > -m option was given. > fatal: revert failed > > > > > Which commit is the one you want to restore the epel7 branch to? cf25d6d? > > > > Yes, > https://src.fedoraproject.org/rpms/petsc4py/c/cf25d6d376fc95034decec02c2e1501f97ae4955?branch=epel7
It failed because it can't tell which branch to restore the state to, since you're reverting a merge commit. "git revert HEAD -m 1" does what you want, I think. "-m 1" tells git to restore to the state of the epel7 branch, not the master branch, which was merged into epel7. Fabio > -- > --- > Antonio Trande > Fedora Project > mailto 'sagitter at fedoraproject dot org' > GPG key: 0x7B30EE04E576AA84 > GPG key server: https://keys.openpgp.org/ > > _______________________________________________ > devel mailing list -- devel@lists.fedoraproject.org > To unsubscribe send an email to devel-le...@lists.fedoraproject.org > Fedora Code of Conduct: > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > List Archives: > https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org _______________________________________________ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org