D6848: narrow: add option for automatically removing unused includes
martinvonz (Martin von Zweigbergk)
phabricator at mercurial-scm.org
Sat Sep 14 01:45:36 EDT 2019
martinvonz added inline comments.
> martinvonz wrote in test-narrow.t:457
> > No, I meant what if you don't get rid of the .i files.
> This is not changing which .i files we get rid of; the behavior should be the same as if you had typed `hg tracked --removeinclude path:d0 --removeinclude path:d2`.
> > But you raise a good point - shouldn't you also clean up the working directory?
> Yes, it should be, but it doesn't print those files if they were clean. I've added a call to `hg files` to the test so you can see that they are cleaned up.
> > Alternatively, or in addition, maybe a confirmation prompt pointing out which commits and
> > narrowspec entries will be dropped may be useful.
> I considered that but I wasn't sure if it would be more annoying than helpful. Want me to add that?
I added that prompt. We also talked about adding a `--dry-run` option instead of the prompt, but that seemed harder because it would need to be handled in many different cases, including `--update-working-copy`, even if we just decide to error out.
CHANGES SINCE LAST ACTION
To: martinvonz, durin42, #hg-reviewers
Cc: rdamazio, mercurial-devel
More information about the Mercurial-devel