comparison tests/test-uncommit.t @ 1143:160fd06312fc

uncommit: abort when rev specifies the current changeset The uncommit command now fails when the rev argument indicates the current changeset. Previously this aborted in the changeset obsolescence machinery when the current commit tries to obsolete itself. Using the rev argument like this indicates a misunderstanding, so printing an uncommit-specific error should make it easier to understand what went wrong.
author Nathan Goldbaum <ngoldbau@ucsc.edu>
date Tue, 28 Oct 2014 18:06:28 -0700
parents f355bbc124fc
children cc3e68120185
comparison
equal deleted inserted replaced
1142:9d85fd6e1474 1143:160fd06312fc
345 $ hg cat b --rev .^ 345 $ hg cat b --rev .^
346 b 346 b
347 $ hg cat b --rev 0 347 $ hg cat b --rev 0
348 b: no such file in rev 07f494440405 348 b: no such file in rev 07f494440405
349 [1] 349 [1]
350 $ hg uncommit --rev . b
351 abort: cannot uncommit to parent changeset
352 [255]
350 $ hg uncommit --rev 0 b 353 $ hg uncommit --rev 0 b
351 $ hg cat b --rev . 354 $ hg cat b --rev .
352 b: no such file in rev 5b27f6b17da2 355 b: no such file in rev 5b27f6b17da2
353 [1] 356 [1]
354 357