Mercurial > hg
view tests/test-username-newline.t @ 38667:572dff5c946e
rebase: add --confirm option
This feature adds a functionality in rebase to confirm before applying
changes.
When there is no conflict and user confirm to apply actions, we just
finish the unfinished rebase. But when there is a conflict and user
confirm to apply actions then we can't just finish rebasing using
rbsrt._finishrebase() because in-memory merge doesn't support conflicts, so
we have to abort and run on-disk merge in this case.
And if user doesn't confirm to apply actions then simply abort the rebase.
Differential Revision: https://phab.mercurial-scm.org/D3870
author | Sushil khanchi <sushilkhanchi97@gmail.com> |
---|---|
date | Sat, 30 Jun 2018 12:42:49 +0530 |
parents | 5ac845ca059a |
children | 95c4cca641f6 |
line wrap: on
line source
$ hg init $ touch a $ unset HGUSER $ echo "[ui]" >> .hg/hgrc $ echo "username= foo" >> .hg/hgrc $ echo " bar1" >> .hg/hgrc $ hg ci -Am m adding a abort: username 'foo\nbar1' contains a newline [255] $ rm .hg/hgrc $ HGUSER=`(echo foo; echo bar2)` hg ci -Am m adding a abort: username 'foo\nbar2' contains a newline [255] $ hg ci -Am m -u "`(echo foo; echo bar3)`" adding a transaction abort! rollback completed abort: username 'foo\nbar3' contains a newline! [255]