2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing hellomessage:
|
|
|
|
|
2011-06-29 16:49:35 +04:00
|
|
|
o, 'capabilities: getencoding runcommand\nencoding: ***'
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand id
|
2011-06-29 16:49:35 +04:00
|
|
|
000000000000 tip
|
2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing unknowncommand:
|
|
|
|
|
2012-02-16 03:23:45 +04:00
|
|
|
abort: unknown command unknowncommand
|
2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing checkruncommand:
|
|
|
|
|
|
|
|
runcommand
|
2011-06-29 16:49:35 +04:00
|
|
|
Mercurial Distributed SCM
|
|
|
|
|
|
|
|
basic commands:
|
|
|
|
|
help: format command and option list help using RST
This patch changes the function which generates help text about commands and
options to use RST formatting. Tables describing options have been formatted
using RST table markup for some time already, so their appearance does not
change. Command lists, however, change appearance.
To format non-verbose command lists, RST field list markup was chosen, because
it resembles the old format:
<http://docutils.sourceforge.net/docs/user/rst/quickref.html#field-lists>
In the old (hand-coded) format of non-verbose command lists, the left column is
12 characters wide. Our minirst implementation formats field lists with a left
column 14 characters wide, so this patch changes the appearance of help output
correspondingly:
<http://markmail.org/message/krl4cxopsnii7s6z?q=mercurial+reinert+from:%22Olav+Reinert%22&page=2>
The minirst markup most closely resembling the old verbose command lists is
definition lists. But using it would cause a blank line to be inserted between
each command definition, making the output excessively long, and no more
useful than before. To avoid this, I chose to use field lists also for verbose
command help, resulting in output like this example:
add add the specified files on the next commit
annotate, blame
show changeset information by line for each file
clone make a copy of an existing repository
commit, ci commit the specified files or all outstanding changes
diff diff repository (or selected files)
export dump the header and diffs for one or more changesets
forget forget the specified files on the next commit
init create a new repository in the given directory
log, history show revision history of entire repository or files
merge merge working directory with another revision
phase set or show the current phase name
pull pull changes from the specified source
push push changes to the specified destination
qdiff diff of the current patch and subsequent modifications
qinit init a new queue repository (DEPRECATED)
qnew create a new patch
qpop pop the current patch off the stack
qpush push the next patch onto the stack
qrefresh update the current patch
remove, rm remove the specified files on the next commit
serve start stand-alone webserver
status, st show changed files in the working directory
summary, sum summarize working directory state
update, up, checkout, co
update working directory (or switch revisions)
This change is a move towards generating all help text as a list of strings
marked up with RST.
2012-06-02 13:25:40 +04:00
|
|
|
add add the specified files on the next commit
|
|
|
|
annotate show changeset information by line for each file
|
|
|
|
clone make a copy of an existing repository
|
|
|
|
commit commit the specified files or all outstanding changes
|
|
|
|
diff diff repository (or selected files)
|
|
|
|
export dump the header and diffs for one or more changesets
|
|
|
|
forget forget the specified files on the next commit
|
|
|
|
init create a new repository in the given directory
|
|
|
|
log show revision history of entire repository or files
|
|
|
|
merge merge working directory with another revision
|
|
|
|
pull pull changes from the specified source
|
|
|
|
push push changes to the specified destination
|
|
|
|
remove remove the specified files on the next commit
|
|
|
|
serve start stand-alone webserver
|
|
|
|
status show changed files in the working directory
|
|
|
|
summary summarize working directory state
|
|
|
|
update update working directory (or switch revisions)
|
2011-06-29 16:49:35 +04:00
|
|
|
|
|
|
|
use "hg help" for the full list of commands or "hg -v" for details
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand id --quiet
|
2011-06-29 16:49:35 +04:00
|
|
|
000000000000
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand id
|
2011-06-29 16:49:35 +04:00
|
|
|
000000000000 tip
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand id --config ui.quiet=True
|
2011-06-29 16:49:35 +04:00
|
|
|
000000000000
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand id
|
2011-06-29 16:49:35 +04:00
|
|
|
000000000000 tip
|
2014-03-03 10:50:51 +04:00
|
|
|
runcommand id -runknown
|
|
|
|
abort: unknown revision 'unknown'!
|
|
|
|
[255]
|
2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing inputeof:
|
|
|
|
|
2011-06-29 16:49:35 +04:00
|
|
|
server exit code = 1
|
2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing serverinput:
|
|
|
|
|
|
|
|
runcommand import -
|
2011-06-29 16:49:35 +04:00
|
|
|
applying patch from stdin
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand log
|
2011-06-29 16:49:35 +04:00
|
|
|
changeset: 0:eff892de26ec
|
|
|
|
tag: tip
|
|
|
|
user: test
|
|
|
|
date: Thu Jan 01 00:00:00 1970 +0000
|
|
|
|
summary: 1
|
|
|
|
|
2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing cwd:
|
|
|
|
|
|
|
|
runcommand --cwd foo st bar
|
2011-07-11 18:49:45 +04:00
|
|
|
? bar
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand st foo/bar
|
2011-07-11 18:49:45 +04:00
|
|
|
? foo/bar
|
2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing localhgrc:
|
|
|
|
|
|
|
|
runcommand showconfig
|
2014-03-03 18:11:17 +04:00
|
|
|
bundle.mainreporoot=$TESTTMP/repo
|
2011-07-14 12:46:15 +04:00
|
|
|
defaults.backout=-d "0 0"
|
|
|
|
defaults.commit=-d "0 0"
|
shelve: add a shelve extension to save/restore working changes
This extension saves shelved changes using a temporary draft commit,
and bundles the temporary commit and its draft ancestors, then
strips them.
This strategy makes it possible to use Mercurial's bundle and merge
machinery to resolve conflicts if necessary when unshelving, even
when the destination commit or its ancestors have been amended,
squashed, or evolved. (Once a change has been unshelved, its
associated unbundled commits are either rolled back or stripped.)
Storing the shelved change as a bundle also avoids the difficulty
that hidden commits would cause, of making it impossible to amend
the parent if it is a draft commits (a common scenario).
Although this extension shares its name and some functionality with
the third party hgshelve extension, it has little else in common.
Notably, the hgshelve extension shelves changes as unified diffs,
which makes conflict resolution a matter of finding .rej files and
conflict markers, and cleaning up the mess by hand.
We do not yet allow hunk-level choosing of changes to record.
Compared to the hgshelve extension, this is a small regression in
usability, but we hope to integrate that at a later point, once the
record machinery becomes more reusable and robust.
2013-08-29 20:22:13 +04:00
|
|
|
defaults.shelve=--date "0 0"
|
2011-07-14 12:46:15 +04:00
|
|
|
defaults.tag=-d "0 0"
|
|
|
|
ui.slash=True
|
2013-01-18 04:23:51 +04:00
|
|
|
ui.interactive=False
|
2011-07-14 12:46:15 +04:00
|
|
|
ui.foo=bar
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand init foo
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand -R foo showconfig ui defaults
|
2011-07-14 12:46:15 +04:00
|
|
|
defaults.backout=-d "0 0"
|
|
|
|
defaults.commit=-d "0 0"
|
shelve: add a shelve extension to save/restore working changes
This extension saves shelved changes using a temporary draft commit,
and bundles the temporary commit and its draft ancestors, then
strips them.
This strategy makes it possible to use Mercurial's bundle and merge
machinery to resolve conflicts if necessary when unshelving, even
when the destination commit or its ancestors have been amended,
squashed, or evolved. (Once a change has been unshelved, its
associated unbundled commits are either rolled back or stripped.)
Storing the shelved change as a bundle also avoids the difficulty
that hidden commits would cause, of making it impossible to amend
the parent if it is a draft commits (a common scenario).
Although this extension shares its name and some functionality with
the third party hgshelve extension, it has little else in common.
Notably, the hgshelve extension shelves changes as unified diffs,
which makes conflict resolution a matter of finding .rej files and
conflict markers, and cleaning up the mess by hand.
We do not yet allow hunk-level choosing of changes to record.
Compared to the hgshelve extension, this is a small regression in
usability, but we hope to integrate that at a later point, once the
record machinery becomes more reusable and robust.
2013-08-29 20:22:13 +04:00
|
|
|
defaults.shelve=--date "0 0"
|
2011-07-14 12:46:15 +04:00
|
|
|
defaults.tag=-d "0 0"
|
|
|
|
ui.slash=True
|
2013-01-18 04:23:51 +04:00
|
|
|
ui.interactive=False
|
2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing hookoutput:
|
|
|
|
|
|
|
|
runcommand --config hooks.pre-identify=python:test-commandserver.hook id
|
2011-07-09 20:06:59 +04:00
|
|
|
hook talking
|
|
|
|
now try to read something: 'some input'
|
|
|
|
eff892de26ec tip
|
2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing outsidechanges:
|
|
|
|
|
2012-02-16 01:44:10 +04:00
|
|
|
runcommand status
|
|
|
|
M a
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand tip
|
2011-07-25 23:19:28 +04:00
|
|
|
changeset: 1:d3a0a68be6de
|
|
|
|
tag: tip
|
|
|
|
user: test
|
|
|
|
date: Thu Jan 01 00:00:00 1970 +0000
|
|
|
|
summary: 2
|
|
|
|
|
2012-02-16 01:44:10 +04:00
|
|
|
runcommand status
|
2011-11-21 03:39:32 +04:00
|
|
|
|
|
|
|
testing bookmarks:
|
|
|
|
|
|
|
|
runcommand bookmarks
|
2011-07-25 23:19:28 +04:00
|
|
|
no bookmarks set
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand bookmarks
|
2011-07-25 23:19:28 +04:00
|
|
|
bm1 1:d3a0a68be6de
|
|
|
|
bm2 1:d3a0a68be6de
|
2011-11-21 03:39:32 +04:00
|
|
|
runcommand bookmarks
|
2011-07-25 23:19:28 +04:00
|
|
|
* bm1 1:d3a0a68be6de
|
|
|
|
bm2 1:d3a0a68be6de
|
2012-02-15 22:02:35 +04:00
|
|
|
runcommand bookmarks bm3
|
|
|
|
runcommand commit -Amm
|
|
|
|
runcommand bookmarks
|
|
|
|
bm1 1:d3a0a68be6de
|
|
|
|
bm2 1:d3a0a68be6de
|
|
|
|
* bm3 2:aef17e88f5f0
|
2011-07-25 23:19:28 +04:00
|
|
|
|
2011-11-21 03:39:32 +04:00
|
|
|
testing tagscache:
|
|
|
|
|
|
|
|
runcommand id -t -r 0
|
|
|
|
|
|
|
|
runcommand id -t -r 0
|
2011-07-25 23:19:28 +04:00
|
|
|
foo
|
2012-01-26 02:21:55 +04:00
|
|
|
|
|
|
|
testing setphase:
|
|
|
|
|
|
|
|
runcommand phase -r .
|
2012-02-15 22:02:35 +04:00
|
|
|
3: draft
|
2012-01-26 02:21:55 +04:00
|
|
|
runcommand phase -r .
|
2012-02-15 22:02:35 +04:00
|
|
|
3: public
|
2012-02-16 03:21:34 +04:00
|
|
|
|
|
|
|
testing rollback:
|
|
|
|
|
|
|
|
runcommand phase -r . -p
|
2012-02-16 03:23:45 +04:00
|
|
|
no phases changed
|
2014-03-03 10:50:48 +04:00
|
|
|
[1]
|
2012-02-16 03:21:34 +04:00
|
|
|
runcommand commit -Am.
|
|
|
|
runcommand rollback
|
|
|
|
repository tip rolled back to revision 3 (undo commit)
|
|
|
|
working directory now based on revision 3
|
|
|
|
runcommand phase -r .
|
|
|
|
3: public
|
2012-03-01 19:42:49 +04:00
|
|
|
|
|
|
|
testing branch:
|
|
|
|
|
|
|
|
runcommand branch
|
|
|
|
default
|
|
|
|
marked working directory as branch foo
|
|
|
|
(branches are permanent and global, did you want a bookmark?)
|
|
|
|
runcommand branch
|
|
|
|
foo
|
|
|
|
marked working directory as branch default
|
|
|
|
(branches are permanent and global, did you want a bookmark?)
|
2012-03-01 19:49:59 +04:00
|
|
|
|
|
|
|
testing hgignore:
|
|
|
|
|
|
|
|
runcommand commit -Am.
|
|
|
|
adding .hgignore
|
|
|
|
runcommand status -i -u
|
|
|
|
I ignored-file
|
2013-03-23 15:34:50 +04:00
|
|
|
|
|
|
|
testing phasecacheafterstrip:
|
|
|
|
|
|
|
|
runcommand update -C 0
|
|
|
|
1 files updated, 0 files merged, 2 files removed, 0 files unresolved
|
|
|
|
runcommand commit -Am. a
|
|
|
|
created new head
|
|
|
|
runcommand log -Gq
|
|
|
|
@ 5:731265503d86
|
|
|
|
|
|
|
|
|
| o 4:7966c8e3734d
|
|
|
|
| |
|
|
|
|
| o 3:b9b85890c400
|
|
|
|
| |
|
|
|
|
| o 2:aef17e88f5f0
|
|
|
|
| |
|
|
|
|
| o 1:d3a0a68be6de
|
|
|
|
|/
|
|
|
|
o 0:eff892de26ec
|
|
|
|
|
|
|
|
runcommand phase -p .
|
|
|
|
runcommand phase .
|
|
|
|
5: public
|
|
|
|
runcommand branches
|
|
|
|
default 1:731265503d86
|
2014-01-27 13:57:20 +04:00
|
|
|
|
|
|
|
testing obsolete:
|
|
|
|
|
|
|
|
runcommand up null
|
|
|
|
0 files updated, 0 files merged, 1 files removed, 0 files unresolved
|
|
|
|
runcommand phase -df tip
|
|
|
|
runcommand log --hidden
|
|
|
|
changeset: 1:731265503d86
|
|
|
|
tag: tip
|
|
|
|
user: test
|
|
|
|
date: Thu Jan 01 00:00:00 1970 +0000
|
|
|
|
summary: .
|
|
|
|
|
|
|
|
changeset: 0:eff892de26ec
|
|
|
|
bookmark: bm1
|
|
|
|
bookmark: bm2
|
|
|
|
bookmark: bm3
|
|
|
|
user: test
|
|
|
|
date: Thu Jan 01 00:00:00 1970 +0000
|
|
|
|
summary: 1
|
|
|
|
|
|
|
|
runcommand log
|
|
|
|
changeset: 0:eff892de26ec
|
|
|
|
bookmark: bm1
|
|
|
|
bookmark: bm2
|
|
|
|
bookmark: bm3
|
|
|
|
tag: tip
|
|
|
|
user: test
|
|
|
|
date: Thu Jan 01 00:00:00 1970 +0000
|
|
|
|
summary: 1
|
|
|
|
|
2014-03-03 14:41:26 +04:00
|
|
|
|
|
|
|
testing mqoutsidechanges:
|
|
|
|
|
|
|
|
runcommand qapplied
|
|
|
|
runcommand qapplied
|
|
|
|
0.diff
|
2014-03-03 14:41:30 +04:00
|
|
|
runcommand qpop --all
|
|
|
|
popping 0.diff
|
|
|
|
patch queue now empty
|
|
|
|
runcommand qqueue --active
|
|
|
|
foo
|
2014-03-03 18:21:24 +04:00
|
|
|
|
|
|
|
testing hellomessage:
|
|
|
|
|
|
|
|
o, 'capabilities: getencoding runcommand\nencoding: ***'
|
|
|
|
runcommand id
|
|
|
|
abort: there is no Mercurial repository here (.hg not found)
|
|
|
|
[255]
|
|
|
|
|
|
|
|
testing startwithoutrepo:
|
|
|
|
|
|
|
|
runcommand init repo2
|
|
|
|
runcommand id -R repo2
|
|
|
|
000000000000 tip
|