468 if isactive: |
468 if isactive: |
469 notice = '' |
469 notice = '' |
470 elif hn not in repo.branchheads(tag, closed=False): |
470 elif hn not in repo.branchheads(tag, closed=False): |
471 if not closed: |
471 if not closed: |
472 continue |
472 continue |
473 notice = ' (closed)' |
473 notice = _(' (closed)') |
474 else: |
474 else: |
475 notice = ' (inactive)' |
475 notice = _(' (inactive)') |
476 rev = str(node).rjust(31 - encoding.colwidth(encodedtag)) |
476 rev = str(node).rjust(31 - encoding.colwidth(encodedtag)) |
477 data = encodedtag, rev, hexfunc(hn), notice |
477 data = encodedtag, rev, hexfunc(hn), notice |
478 ui.write("%s %s:%s%s\n" % data) |
478 ui.write("%s %s:%s%s\n" % data) |
479 |
479 |
480 def bundle(ui, repo, fname, dest=None, **opts): |
480 def bundle(ui, repo, fname, dest=None, **opts): |
590 The location of the source is added to the new repository's |
590 The location of the source is added to the new repository's |
591 .hg/hgrc file, as the default to be used for future pulls. |
591 .hg/hgrc file, as the default to be used for future pulls. |
592 |
592 |
593 See 'hg help urls' for valid source format details. |
593 See 'hg help urls' for valid source format details. |
594 |
594 |
595 It is possible to specify an ssh:// URL as the destination, but no |
595 It is possible to specify an ``ssh://`` URL as the destination, but no |
596 .hg/hgrc and working directory will be created on the remote side. |
596 .hg/hgrc and working directory will be created on the remote side. |
597 Please see 'hg help urls' for important details about ssh:// URLs. |
597 Please see 'hg help urls' for important details about ``ssh://`` URLs. |
598 |
598 |
599 If the -U/--noupdate option is specified, the new clone will contain |
599 If the -U/--noupdate option is specified, the new clone will contain |
600 only a repository (.hg) and no working copy (the working copy parent |
600 only a repository (.hg) and no working copy (the working copy parent |
601 will be the null changeset). Otherwise, clone will initially check |
601 will be the null changeset). Otherwise, clone will initially check |
602 out (in order of precedence): |
602 out (in order of precedence): |
1937 Initialize a new repository in the given directory. If the given |
1937 Initialize a new repository in the given directory. If the given |
1938 directory does not exist, it will be created. |
1938 directory does not exist, it will be created. |
1939 |
1939 |
1940 If no directory is given, the current directory is used. |
1940 If no directory is given, the current directory is used. |
1941 |
1941 |
1942 It is possible to specify an ssh:// URL as the destination. |
1942 It is possible to specify an ``ssh://`` URL as the destination. |
1943 See 'hg help urls' for more information. |
1943 See 'hg help urls' for more information. |
1944 """ |
1944 """ |
1945 hg.repository(cmdutil.remoteui(ui, opts), dest, create=1) |
1945 hg.repository(cmdutil.remoteui(ui, opts), dest, create=1) |
1946 |
1946 |
1947 def locate(ui, repo, *pats, **opts): |
1947 def locate(ui, repo, *pats, **opts): |
2328 user forgot to pull and merge before pushing. |
2328 user forgot to pull and merge before pushing. |
2329 |
2329 |
2330 If -r/--rev is used, the named revision and all its ancestors will |
2330 If -r/--rev is used, the named revision and all its ancestors will |
2331 be pushed to the remote repository. |
2331 be pushed to the remote repository. |
2332 |
2332 |
2333 Please see 'hg help urls' for important details about ssh:// |
2333 Please see 'hg help urls' for important details about ``ssh://`` |
2334 URLs. If DESTINATION is omitted, a default path will be used. |
2334 URLs. If DESTINATION is omitted, a default path will be used. |
2335 """ |
2335 """ |
2336 dest, revs, checkout = hg.parseurl( |
2336 dest, revs, checkout = hg.parseurl( |
2337 ui.expandpath(dest or 'default-push', dest or 'default'), opts.get('rev')) |
2337 ui.expandpath(dest or 'default-push', dest or 'default'), opts.get('rev')) |
2338 other = hg.repository(cmdutil.remoteui(repo, opts), dest) |
2338 other = hg.repository(cmdutil.remoteui(repo, opts), dest) |
3337 ('g', 'good', False, _('mark changeset good')), |
3337 ('g', 'good', False, _('mark changeset good')), |
3338 ('b', 'bad', False, _('mark changeset bad')), |
3338 ('b', 'bad', False, _('mark changeset bad')), |
3339 ('s', 'skip', False, _('skip testing changeset')), |
3339 ('s', 'skip', False, _('skip testing changeset')), |
3340 ('c', 'command', '', _('use command to check changeset state')), |
3340 ('c', 'command', '', _('use command to check changeset state')), |
3341 ('U', 'noupdate', False, _('do not update to target'))], |
3341 ('U', 'noupdate', False, _('do not update to target'))], |
3342 _("[-gbsr] [-c CMD] [REV]")), |
3342 _("[-gbsr] [-U] [-c CMD] [REV]")), |
3343 "branch": |
3343 "branch": |
3344 (branch, |
3344 (branch, |
3345 [('f', 'force', None, |
3345 [('f', 'force', None, |
3346 _('set branch name even if it shadows an existing branch')), |
3346 _('set branch name even if it shadows an existing branch')), |
3347 ('C', 'clean', None, _('reset branch name to parent branch name'))], |
3347 ('C', 'clean', None, _('reset branch name to parent branch name'))], |
3350 (branches, |
3350 (branches, |
3351 [('a', 'active', False, |
3351 [('a', 'active', False, |
3352 _('show only branches that have unmerged heads')), |
3352 _('show only branches that have unmerged heads')), |
3353 ('c', 'closed', False, |
3353 ('c', 'closed', False, |
3354 _('show normal and closed branches'))], |
3354 _('show normal and closed branches'))], |
3355 _('[-a]')), |
3355 _('[-ac]')), |
3356 "bundle": |
3356 "bundle": |
3357 (bundle, |
3357 (bundle, |
3358 [('f', 'force', None, |
3358 [('f', 'force', None, |
3359 _('run even when remote repository is unrelated')), |
3359 _('run even when remote repository is unrelated')), |
3360 ('r', 'rev', [], |
3360 ('r', 'rev', [], |
3362 ('', 'base', [], |
3362 ('', 'base', [], |
3363 _('a base changeset to specify instead of a destination')), |
3363 _('a base changeset to specify instead of a destination')), |
3364 ('a', 'all', None, _('bundle all changesets in the repository')), |
3364 ('a', 'all', None, _('bundle all changesets in the repository')), |
3365 ('t', 'type', 'bzip2', _('bundle compression type to use')), |
3365 ('t', 'type', 'bzip2', _('bundle compression type to use')), |
3366 ] + remoteopts, |
3366 ] + remoteopts, |
3367 _('[-f] [-a] [-r REV]... [--base REV]... FILE [DEST]')), |
3367 _('[-f] [-t TYPE] [-a] [-r REV]... [--base REV]... FILE [DEST]')), |
3368 "cat": |
3368 "cat": |
3369 (cat, |
3369 (cat, |
3370 [('o', 'output', '', _('print output to file with formatted name')), |
3370 [('o', 'output', '', _('print output to file with formatted name')), |
3371 ('r', 'rev', '', _('print the given revision')), |
3371 ('r', 'rev', '', _('print the given revision')), |
3372 ('', 'decode', None, _('apply any matching decode filter')), |
3372 ('', 'decode', None, _('apply any matching decode filter')), |
3472 ('a', 'active', False, |
3472 ('a', 'active', False, |
3473 _('show only the active branch heads from open branches')), |
3473 _('show only the active branch heads from open branches')), |
3474 ('c', 'closed', False, |
3474 ('c', 'closed', False, |
3475 _('show normal and closed branch heads')), |
3475 _('show normal and closed branch heads')), |
3476 ] + templateopts, |
3476 ] + templateopts, |
3477 _('[-r STARTREV] [REV]...')), |
3477 _('[-ac] [-r STARTREV] [REV]...')), |
3478 "help": (help_, [], _('[TOPIC]')), |
3478 "help": (help_, [], _('[TOPIC]')), |
3479 "identify|id": |
3479 "identify|id": |
3480 (identify, |
3480 (identify, |
3481 [('r', 'rev', '', _('identify the specified revision')), |
3481 [('r', 'rev', '', _('identify the specified revision')), |
3482 ('n', 'num', None, _('show local revision number')), |
3482 ('n', 'num', None, _('show local revision number')), |
3549 (merge, |
3549 (merge, |
3550 [('f', 'force', None, _('force a merge with outstanding changes')), |
3550 [('f', 'force', None, _('force a merge with outstanding changes')), |
3551 ('r', 'rev', '', _('revision to merge')), |
3551 ('r', 'rev', '', _('revision to merge')), |
3552 ('P', 'preview', None, |
3552 ('P', 'preview', None, |
3553 _('review revisions to merge (no merge is performed)'))], |
3553 _('review revisions to merge (no merge is performed)'))], |
3554 _('[-f] [[-r] REV]')), |
3554 _('[-P] [-f] [[-r] REV]')), |
3555 "outgoing|out": |
3555 "outgoing|out": |
3556 (outgoing, |
3556 (outgoing, |
3557 [('f', 'force', None, |
3557 [('f', 'force', None, |
3558 _('run even when remote repository is unrelated')), |
3558 _('run even when remote repository is unrelated')), |
3559 ('r', 'rev', [], |
3559 ('r', 'rev', [], |
3669 ('r', 'rev', '', _('revision to tag')), |
3669 ('r', 'rev', '', _('revision to tag')), |
3670 ('', 'remove', None, _('remove a tag')), |
3670 ('', 'remove', None, _('remove a tag')), |
3671 # -l/--local is already there, commitopts cannot be used |
3671 # -l/--local is already there, commitopts cannot be used |
3672 ('m', 'message', '', _('use <text> as commit message')), |
3672 ('m', 'message', '', _('use <text> as commit message')), |
3673 ] + commitopts2, |
3673 ] + commitopts2, |
3674 _('[-l] [-m TEXT] [-d DATE] [-u USER] [-r REV] NAME...')), |
3674 _('[-f] [-l] [-m TEXT] [-d DATE] [-u USER] [-r REV] NAME...')), |
3675 "tags": (tags, [], ''), |
3675 "tags": (tags, [], ''), |
3676 "tip": |
3676 "tip": |
3677 (tip, |
3677 (tip, |
3678 [('p', 'patch', None, _('show patch')), |
3678 [('p', 'patch', None, _('show patch')), |
3679 ('g', 'git', None, _('use git extended diff format')), |
3679 ('g', 'git', None, _('use git extended diff format')), |
3680 ] + templateopts, |
3680 ] + templateopts, |
3681 _('[-p]')), |
3681 _('[-p] [-g]')), |
3682 "unbundle": |
3682 "unbundle": |
3683 (unbundle, |
3683 (unbundle, |
3684 [('u', 'update', None, |
3684 [('u', 'update', None, |
3685 _('update to new tip if changesets were unbundled'))], |
3685 _('update to new tip if changesets were unbundled'))], |
3686 _('[-u] FILE...')), |
3686 _('[-u] FILE...')), |