Show More
@@ -226,6 +226,7 b' def createcmd(ui, repo, pats, opts):' | |||
|
226 | 226 | raise util.Abort(_('shelved change names may not contain slashes')) |
|
227 | 227 | if name.startswith('.'): |
|
228 | 228 | raise util.Abort(_("shelved change names may not start with '.'")) |
|
229 | interactive = opts.get('interactive', False) | |
|
229 | 230 | |
|
230 | 231 | node = cmdutil.commit(ui, repo, commitfunc, pats, opts) |
|
231 | 232 | |
@@ -649,6 +650,8 b' def unshelve(ui, repo, *shelved, **opts)' | |||
|
649 | 650 | _('use the given name for the shelved commit'), _('NAME')), |
|
650 | 651 | ('p', 'patch', None, |
|
651 | 652 | _('show patch')), |
|
653 | ('i', 'interactive', None, | |
|
654 | _('interactive mode, only works while creating a shelve')), | |
|
652 | 655 | ('', 'stat', None, |
|
653 | 656 | _('output diffstat-style summary of changes'))] + commands.walkopts, |
|
654 | 657 | _('hg shelve [OPTION]... [FILE]...')) |
@@ -17,6 +17,57 b'' | |||
|
17 | 17 | $ echo x > x |
|
18 | 18 | $ hg addremove -q |
|
19 | 19 | |
|
20 | shelve has a help message | |
|
21 | $ hg shelve -h | |
|
22 | hg shelve [OPTION]... [FILE]... | |
|
23 | ||
|
24 | save and set aside changes from the working directory | |
|
25 | ||
|
26 | Shelving takes files that "hg status" reports as not clean, saves the | |
|
27 | modifications to a bundle (a shelved change), and reverts the files so | |
|
28 | that their state in the working directory becomes clean. | |
|
29 | ||
|
30 | To restore these changes to the working directory, using "hg unshelve"; | |
|
31 | this will work even if you switch to a different commit. | |
|
32 | ||
|
33 | When no files are specified, "hg shelve" saves all not-clean files. If | |
|
34 | specific files or directories are named, only changes to those files are | |
|
35 | shelved. | |
|
36 | ||
|
37 | Each shelved change has a name that makes it easier to find later. The | |
|
38 | name of a shelved change defaults to being based on the active bookmark, | |
|
39 | or if there is no active bookmark, the current named branch. To specify a | |
|
40 | different name, use "--name". | |
|
41 | ||
|
42 | To see a list of existing shelved changes, use the "--list" option. For | |
|
43 | each shelved change, this will print its name, age, and description; use " | |
|
44 | --patch" or "--stat" for more details. | |
|
45 | ||
|
46 | To delete specific shelved changes, use "--delete". To delete all shelved | |
|
47 | changes, use "--cleanup". | |
|
48 | ||
|
49 | (use "hg help -e shelve" to show help for the shelve extension) | |
|
50 | ||
|
51 | options ([+] can be repeated): | |
|
52 | ||
|
53 | -A --addremove mark new/missing files as added/removed before | |
|
54 | shelving | |
|
55 | --cleanup delete all shelved changes | |
|
56 | --date DATE shelve with the specified commit date | |
|
57 | -d --delete delete the named shelved change(s) | |
|
58 | -e --edit invoke editor on commit messages | |
|
59 | -l --list list current shelves | |
|
60 | -m --message TEXT use text as shelve message | |
|
61 | -n --name NAME use the given name for the shelved commit | |
|
62 | -p --patch show patch | |
|
63 | -i --interactive interactive mode, only works while creating a shelve | |
|
64 | --stat output diffstat-style summary of changes | |
|
65 | -I --include PATTERN [+] include names matching the given patterns | |
|
66 | -X --exclude PATTERN [+] exclude names matching the given patterns | |
|
67 | --mq operate on patch repository | |
|
68 | ||
|
69 | (some details hidden, use --verbose to show complete help) | |
|
70 | ||
|
20 | 71 | shelving in an empty repo should be possible |
|
21 | 72 | (this tests also that editor is not invoked, if '--edit' is not |
|
22 | 73 | specified) |
General Comments 0
You need to be logged in to leave comments.
Login now