next: improve the message for dirty working copy with --evolve
This will be important soon when --evolve will be the default.
--- a/hgext3rd/evolve/__init__.py Sat Nov 10 16:01:31 2018 +0100
+++ b/hgext3rd/evolve/__init__.py Sat Nov 10 16:05:34 2018 +0100
@@ -1130,7 +1130,8 @@
# check for dirty wdir if --evolve is passed
if opts['evolve']:
- cmdutil.bailifchanged(repo)
+ hint = _('use `hg amend`, `hg revert` or `hg shelve`')
+ cmdutil.bailifchanged(repo, hint=hint)
children = [ctx for ctx in wparents[0].children() if not ctx.obsolete()]
topic = _getcurrenttopic(repo)
--- a/tests/test-prev-next.t Sat Nov 10 16:01:31 2018 +0100
+++ b/tests/test-prev-next.t Sat Nov 10 16:05:34 2018 +0100
@@ -375,6 +375,7 @@
$ hg next --evolve
abort: uncommitted changes
+ (use `hg amend`, `hg revert` or `hg shelve`)
[255]
$ cd ..