On 09/13/2016 06:48 PM, Yves S. Garret wrote:
Hello,

I'm just setting things up. I don't care too much if I lose the history of what I did (since I'm just getting the ball rolling.) I've looked online to try to fix a corrupt repo problem [https://www.mercurial-scm.org/wiki/RepositoryCorruption#Repository_corruption], but could not resolve my problem successfully. Below is what I see when I try to run hg status and hg verify.

I was committing some source files, but wanted to remove the generated binaries (*.o and *.exe), and did things such as: rm $(find . -name "*.o") and rm $(find . -name "*.exe")

As a side note, a better way to do that cleanup would be with ``hg purge``.

  hg purge -I 'glob:**.o' -I 'glob:**.exe'

would work, as would

  hg purge -I 'glob:**.{o,exe}'

though paranoid people like me almost never run purge without -p/-0, so personally I would probably run

  hg purge -p -I 'glob:**.{o,exe}'

then eyeball the results, and if they looked right,

  hg purge -0 -I 'glob:**.{o,exe}' | xargs -0 rm

Though if your goal really is to eliminate all generated files, and you're sure you've added everything necessary, a plain ``hg purge`` is pretty handy. (Perhaps after running ``hg purge -p`` to check.)

_______________________________________________
Mercurial mailing list
Mercurial@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial

Reply via email to