##// END OF EJS Templates
commands: optional options where possible...
Alexander Solovyov -
r7131:23bd7383 default
parent child Browse files
Show More
@@ -94,12 +94,12 b' def annotate(ui, repo, *pats, **opts):'
94 94 ('follow', lambda x: x[0].path()),
95 95 ]
96 96
97 if (not opts['user'] and not opts['changeset'] and not opts['date']
98 and not opts['follow']):
97 if (not opts.get('user') and not opts.get('changeset') and not opts.get('date')
98 and not opts.get('follow')):
99 99 opts['number'] = 1
100 100
101 101 linenumber = opts.get('line_number') is not None
102 if (linenumber and (not opts['changeset']) and (not opts['number'])):
102 if (linenumber and (not opts.get('changeset')) and (not opts.get('number'))):
103 103 raise util.Abort(_('at least one of -n/-c is required for -l'))
104 104
105 105 funcmap = [func for op, func in opmap if opts.get(op)]
@@ -107,12 +107,12 b' def annotate(ui, repo, *pats, **opts):'
107 107 lastfunc = funcmap[-1]
108 108 funcmap[-1] = lambda x: "%s:%s" % (lastfunc(x), x[1])
109 109
110 ctx = repo[opts['rev']]
110 ctx = repo[opts.get('rev')]
111 111
112 112 m = cmdutil.match(repo, pats, opts)
113 113 for abs in ctx.walk(m):
114 114 fctx = ctx[abs]
115 if not opts['text'] and util.binary(fctx.data()):
115 if not opts.get('text') and util.binary(fctx.data()):
116 116 ui.write(_("%s: binary file\n") % ((pats and m.rel(abs)) or abs))
117 117 continue
118 118
@@ -154,7 +154,7 b' def archive(ui, repo, dest, **opts):'
154 154 The default is the basename of the archive, with suffixes removed.
155 155 '''
156 156
157 ctx = repo[opts['rev']]
157 ctx = repo[opts.get('rev')]
158 158 if not ctx:
159 159 raise util.Abort(_('repository has no revisions'))
160 160 node = ctx.node()
@@ -163,14 +163,14 b' def archive(ui, repo, dest, **opts):'
163 163 raise util.Abort(_('repository root cannot be destination'))
164 164 matchfn = cmdutil.match(repo, [], opts)
165 165 kind = opts.get('type') or 'files'
166 prefix = opts['prefix']
166 prefix = opts.get('prefix')
167 167 if dest == '-':
168 168 if kind == 'files':
169 169 raise util.Abort(_('cannot archive plain files to stdout'))
170 170 dest = sys.stdout
171 171 if not prefix: prefix = os.path.basename(repo.root) + '-%h'
172 172 prefix = cmdutil.make_filename(repo, prefix, node)
173 archival.archive(repo, dest, node, kind, not opts['no_decode'],
173 archival.archive(repo, dest, node, kind, not opts.get('no_decode'),
174 174 matchfn, prefix)
175 175
176 176 def backout(ui, repo, node=None, rev=None, **opts):
@@ -216,7 +216,7 b' def backout(ui, repo, node=None, rev=Non'
216 216 if p1 == nullid:
217 217 raise util.Abort(_('cannot back out a change with no parents'))
218 218 if p2 != nullid:
219 if not opts['parent']:
219 if not opts.get('parent'):
220 220 raise util.Abort(_('cannot back out a merge changeset without '
221 221 '--parent'))
222 222 p = repo.lookup(opts['parent'])
@@ -225,7 +225,7 b' def backout(ui, repo, node=None, rev=Non'
225 225 (short(p), short(node)))
226 226 parent = p
227 227 else:
228 if opts['parent']:
228 if opts.get('parent'):
229 229 raise util.Abort(_('cannot use --parent on non-merge changeset'))
230 230 parent = p1
231 231
@@ -251,7 +251,7 b' def backout(ui, repo, node=None, rev=Non'
251 251 (nice(repo.changelog.tip()), nice(node)))
252 252 if op1 != node:
253 253 hg.clean(repo, op1, show_stats=False)
254 if opts['merge']:
254 if opts.get('merge'):
255 255 ui.status(_('merging with changeset %s\n') % nice(repo.changelog.tip()))
256 256 hg.merge(repo, hex(repo.changelog.tip()))
257 257 else:
@@ -478,7 +478,7 b' def bundle(ui, repo, fname, dest=None, *'
478 478 dest, revs, checkout = hg.parseurl(
479 479 ui.expandpath(dest or 'default-push', dest or 'default'), revs)
480 480 other = hg.repository(ui, dest)
481 o = repo.findoutgoing(other, force=opts['force'])
481 o = repo.findoutgoing(other, force=opts.get('force'))
482 482
483 483 if revs:
484 484 cg = repo.changegroupsubset(o, revs, 'bundle')
@@ -508,11 +508,11 b' def cat(ui, repo, file1, *pats, **opts):'
508 508 %d dirname of file being printed, or '.' if in repo root
509 509 %p root-relative path name of file being printed
510 510 """
511 ctx = repo[opts['rev']]
511 ctx = repo[opts.get('rev')]
512 512 err = 1
513 513 m = cmdutil.match(repo, (file1,) + pats, opts)
514 514 for abs in ctx.walk(m):
515 fp = cmdutil.make_file(repo, opts['output'], ctx.node(), pathname=abs)
515 fp = cmdutil.make_file(repo, opts.get('output'), ctx.node(), pathname=abs)
516 516 data = ctx[abs].data()
517 517 if opts.get('decode'):
518 518 data = repo.wwritedata(abs, data)
@@ -566,10 +566,10 b' def clone(ui, source, dest=None, **opts)'
566 566 """
567 567 cmdutil.setremoteconfig(ui, opts)
568 568 hg.clone(ui, source, dest,
569 pull=opts['pull'],
570 stream=opts['uncompressed'],
571 rev=opts['rev'],
572 update=not opts['noupdate'])
569 pull=opts.get('pull'),
570 stream=opts.get('uncompressed'),
571 rev=opts.get('rev'),
572 update=not opts.get('noupdate'))
573 573
574 574 def commit(ui, repo, *pats, **opts):
575 575 """commit the specified files or all outstanding changes
@@ -588,7 +588,7 b' def commit(ui, repo, *pats, **opts):'
588 588 See 'hg help dates' for a list of formats valid for -d/--date.
589 589 """
590 590 def commitfunc(ui, repo, message, match, opts):
591 return repo.commit(match.files(), message, opts['user'], opts['date'],
591 return repo.commit(match.files(), message, opts.get('user'), opts.get('date'),
592 592 match, force_editor=opts.get('force_editor'))
593 593
594 594 node = cmdutil.commit(ui, repo, commitfunc, pats, opts)
@@ -651,7 +651,7 b' def debugancestor(ui, repo, *args):'
651 651 def debugcomplete(ui, cmd='', **opts):
652 652 """returns the completion list associated with the given command"""
653 653
654 if opts['options']:
654 if opts.get('options'):
655 655 options = []
656 656 otables = [globalopts]
657 657 if cmd:
@@ -981,7 +981,7 b' def diff(ui, repo, *pats, **opts):'
981 981 it detects as binary. With -a, diff will generate a diff anyway,
982 982 probably with undesirable results.
983 983 """
984 node1, node2 = cmdutil.revpair(repo, opts['rev'])
984 node1, node2 = cmdutil.revpair(repo, opts.get('rev'))
985 985
986 986 m = cmdutil.match(repo, pats, opts)
987 987 patch.diff(repo, node1, node2, match=m, opts=patch.diffopts(ui, opts))
@@ -1023,8 +1023,8 b' def export(ui, repo, *changesets, **opts'
1023 1023 ui.note(_('exporting patches:\n'))
1024 1024 else:
1025 1025 ui.note(_('exporting patch:\n'))
1026 patch.export(repo, revs, template=opts['output'],
1027 switch_parent=opts['switch_parent'],
1026 patch.export(repo, revs, template=opts.get('output'),
1027 switch_parent=opts.get('switch_parent'),
1028 1028 opts=patch.diffopts(ui, opts))
1029 1029
1030 1030 def grep(ui, repo, pattern, *pats, **opts):
@@ -1044,7 +1044,7 b' def grep(ui, repo, pattern, *pats, **opt'
1044 1044 use the --all flag.
1045 1045 """
1046 1046 reflags = 0
1047 if opts['ignore_case']:
1047 if opts.get('ignore_case'):
1048 1048 reflags |= re.I
1049 1049 try:
1050 1050 regexp = re.compile(pattern, reflags)
@@ -1052,7 +1052,7 b' def grep(ui, repo, pattern, *pats, **opt'
1052 1052 ui.warn(_("grep: invalid match pattern: %s\n") % inst)
1053 1053 return None
1054 1054 sep, eol = ':', '\n'
1055 if opts['print0']:
1055 if opts.get('print0'):
1056 1056 sep = eol = '\0'
1057 1057
1058 1058 fcache = {}
@@ -1118,21 +1118,21 b' def grep(ui, repo, pattern, *pats, **opt'
1118 1118 found = False
1119 1119 filerevmatches = {}
1120 1120 r = prev.get(fn, -1)
1121 if opts['all']:
1121 if opts.get('all'):
1122 1122 iter = difflinestates(states, prevstates)
1123 1123 else:
1124 1124 iter = [('', l) for l in prevstates]
1125 1125 for change, l in iter:
1126 1126 cols = [fn, str(r)]
1127 if opts['line_number']:
1127 if opts.get('line_number'):
1128 1128 cols.append(str(l.linenum))
1129 if opts['all']:
1129 if opts.get('all'):
1130 1130 cols.append(change)
1131 if opts['user']:
1131 if opts.get('user'):
1132 1132 cols.append(ui.shortuser(get(r)[1]))
1133 1133 if opts.get('date'):
1134 1134 cols.append(datefunc(get(r)[2]))
1135 if opts['files_with_matches']:
1135 if opts.get('files_with_matches'):
1136 1136 c = (fn, r)
1137 1137 if c in filerevmatches:
1138 1138 continue
@@ -1177,7 +1177,7 b' def grep(ui, repo, pattern, *pats, **opt'
1177 1177 if fn in prev or fstate[fn]:
1178 1178 r = display(fn, rev, m, fstate[fn])
1179 1179 found = found or r
1180 if r and not opts['all']:
1180 if r and not opts.get('all'):
1181 1181 skip[fn] = True
1182 1182 if copy:
1183 1183 skip[copy] = True
@@ -1210,7 +1210,7 b' def heads(ui, repo, *branchrevs, **opts)'
1210 1210 no child changesets with that tag. They are usually where
1211 1211 development on the given branch takes place.
1212 1212 """
1213 if opts['rev']:
1213 if opts.get('rev'):
1214 1214 start = repo.lookup(opts['rev'])
1215 1215 else:
1216 1216 start = None
@@ -1230,10 +1230,10 b' def heads(ui, repo, *branchrevs, **opts)'
1230 1230 if branch != branchrev:
1231 1231 ui.warn(_("no changes on branch %s containing %s are "
1232 1232 "reachable from %s\n")
1233 % (branch, branchrev, opts['rev']))
1233 % (branch, branchrev, opts.get('rev')))
1234 1234 else:
1235 1235 ui.warn(_("no changes on branch %s are reachable from %s\n")
1236 % (branch, opts['rev']))
1236 % (branch, opts.get('rev')))
1237 1237 heads.extend(bheads)
1238 1238 if not heads:
1239 1239 return 1
@@ -1553,7 +1553,7 b' def import_(ui, repo, patch1, *patches, '
1553 1553 if date:
1554 1554 opts['date'] = util.parsedate(date)
1555 1555
1556 if opts.get('exact') or not opts['force']:
1556 if opts.get('exact') or not opts.get('force'):
1557 1557 cmdutil.bail_if_changed(repo)
1558 1558
1559 1559 d = opts["base"]
@@ -1648,7 +1648,7 b' def incoming(ui, repo, source="default",'
1648 1648 See pull for valid source format details.
1649 1649 """
1650 1650 limit = cmdutil.loglimit(opts)
1651 source, revs, checkout = hg.parseurl(ui.expandpath(source), opts['rev'])
1651 source, revs, checkout = hg.parseurl(ui.expandpath(source), opts.get('rev'))
1652 1652 cmdutil.setremoteconfig(ui, opts)
1653 1653
1654 1654 other = hg.repository(ui, source)
@@ -1683,7 +1683,7 b' def incoming(ui, repo, source="default",'
1683 1683 other = bundlerepo.bundlerepository(ui, repo.root, fname)
1684 1684
1685 1685 o = other.changelog.nodesbetween(incoming, revs)[0]
1686 if opts['newest_first']:
1686 if opts.get('newest_first'):
1687 1687 o.reverse()
1688 1688 displayer = cmdutil.show_changeset(ui, other, opts)
1689 1689 count = 0
@@ -1691,7 +1691,7 b' def incoming(ui, repo, source="default",'
1691 1691 if count >= limit:
1692 1692 break
1693 1693 parents = [p for p in other.changelog.parents(n) if p != nullid]
1694 if opts['no_merges'] and len(parents) == 2:
1694 if opts.get('no_merges') and len(parents) == 2:
1695 1695 continue
1696 1696 count += 1
1697 1697 displayer.show(changenode=n)
@@ -1734,7 +1734,7 b' def locate(ui, repo, *pats, **opts):'
1734 1734 This will avoid the problem of "xargs" treating single filenames
1735 1735 that contain white space as multiple filenames.
1736 1736 """
1737 end = opts['print0'] and '\0' or '\n'
1737 end = opts.get('print0') and '\0' or '\n'
1738 1738 rev = opts.get('rev') or None
1739 1739
1740 1740 ret = 1
@@ -1743,7 +1743,7 b' def locate(ui, repo, *pats, **opts):'
1743 1743 for abs in repo[rev].walk(m):
1744 1744 if not rev and abs not in repo.dirstate:
1745 1745 continue
1746 if opts['fullpath']:
1746 if opts.get('fullpath'):
1747 1747 ui.write(os.path.join(repo.root, abs), end)
1748 1748 else:
1749 1749 ui.write(((pats and m.rel(abs)) or abs), end)
@@ -1787,8 +1787,8 b' def log(ui, repo, *pats, **opts):'
1787 1787 limit = cmdutil.loglimit(opts)
1788 1788 count = 0
1789 1789
1790 if opts['copies'] and opts['rev']:
1791 endrev = max(cmdutil.revrange(repo, opts['rev'])) + 1
1790 if opts.get('copies') and opts.get('rev'):
1791 endrev = max(cmdutil.revrange(repo, opts.get('rev'))) + 1
1792 1792 else:
1793 1793 endrev = len(repo)
1794 1794 rcache = {}
@@ -1827,7 +1827,7 b' def log(ui, repo, *pats, **opts):'
1827 1827 if opts["date"]:
1828 1828 df = util.matchdate(opts["date"])
1829 1829
1830 only_branches = opts['only_branch']
1830 only_branches = opts.get('only_branch')
1831 1831
1832 1832 displayer = cmdutil.show_changeset(ui, repo, opts, True, matchfn)
1833 1833 for st, rev, fns in changeiter:
@@ -1835,9 +1835,9 b' def log(ui, repo, *pats, **opts):'
1835 1835 changenode = repo.changelog.node(rev)
1836 1836 parents = [p for p in repo.changelog.parentrevs(rev)
1837 1837 if p != nullrev]
1838 if opts['no_merges'] and len(parents) == 2:
1838 if opts.get('no_merges') and len(parents) == 2:
1839 1839 continue
1840 if opts['only_merges'] and len(parents) != 2:
1840 if opts.get('only_merges') and len(parents) != 2:
1841 1841 continue
1842 1842
1843 1843 if only_branches:
@@ -1850,7 +1850,7 b' def log(ui, repo, *pats, **opts):'
1850 1850 if not df(changes[2][0]):
1851 1851 continue
1852 1852
1853 if opts['keyword']:
1853 if opts.get('keyword'):
1854 1854 changes = get(rev)
1855 1855 miss = 0
1856 1856 for k in [kw.lower() for kw in opts['keyword']]:
@@ -1958,19 +1958,19 b' def outgoing(ui, repo, dest=None, **opts'
1958 1958 """
1959 1959 limit = cmdutil.loglimit(opts)
1960 1960 dest, revs, checkout = hg.parseurl(
1961 ui.expandpath(dest or 'default-push', dest or 'default'), opts['rev'])
1961 ui.expandpath(dest or 'default-push', dest or 'default'), opts.get('rev'))
1962 1962 cmdutil.setremoteconfig(ui, opts)
1963 1963 if revs:
1964 1964 revs = [repo.lookup(rev) for rev in revs]
1965 1965
1966 1966 other = hg.repository(ui, dest)
1967 1967 ui.status(_('comparing with %s\n') % util.hidepassword(dest))
1968 o = repo.findoutgoing(other, force=opts['force'])
1968 o = repo.findoutgoing(other, force=opts.get('force'))
1969 1969 if not o:
1970 1970 ui.status(_("no changes found\n"))
1971 1971 return 1
1972 1972 o = repo.changelog.nodesbetween(o, revs)[0]
1973 if opts['newest_first']:
1973 if opts.get('newest_first'):
1974 1974 o.reverse()
1975 1975 displayer = cmdutil.show_changeset(ui, repo, opts)
1976 1976 count = 0
@@ -1978,7 +1978,7 b' def outgoing(ui, repo, dest=None, **opts'
1978 1978 if count >= limit:
1979 1979 break
1980 1980 parents = [p for p in repo.changelog.parents(n) if p != nullid]
1981 if opts['no_merges'] and len(parents) == 2:
1981 if opts.get('no_merges') and len(parents) == 2:
1982 1982 continue
1983 1983 count += 1
1984 1984 displayer.show(changenode=n)
@@ -2097,7 +2097,7 b' def pull(ui, repo, source="default", **o'
2097 2097 Alternatively specify "ssh -C" as your ssh command in your hgrc or
2098 2098 with the --ssh command line option.
2099 2099 """
2100 source, revs, checkout = hg.parseurl(ui.expandpath(source), opts['rev'])
2100 source, revs, checkout = hg.parseurl(ui.expandpath(source), opts.get('rev'))
2101 2101 cmdutil.setremoteconfig(ui, opts)
2102 2102
2103 2103 other = hg.repository(ui, source)
@@ -2110,8 +2110,8 b' def pull(ui, repo, source="default", **o'
2110 2110 "so a rev cannot be specified.")
2111 2111 raise util.Abort(error)
2112 2112
2113 modheads = repo.pull(other, heads=revs, force=opts['force'])
2114 return postincoming(ui, repo, modheads, opts['update'], checkout)
2113 modheads = repo.pull(other, heads=revs, force=opts.get('force'))
2114 return postincoming(ui, repo, modheads, opts.get('update'), checkout)
2115 2115
2116 2116 def push(ui, repo, dest=None, **opts):
2117 2117 """push changes to the specified destination
@@ -2145,14 +2145,14 b' def push(ui, repo, dest=None, **opts):'
2145 2145 feature is explicitly enabled on the remote Mercurial server.
2146 2146 """
2147 2147 dest, revs, checkout = hg.parseurl(
2148 ui.expandpath(dest or 'default-push', dest or 'default'), opts['rev'])
2148 ui.expandpath(dest or 'default-push', dest or 'default'), opts.get('rev'))
2149 2149 cmdutil.setremoteconfig(ui, opts)
2150 2150
2151 2151 other = hg.repository(ui, dest)
2152 2152 ui.status(_('pushing to %s\n') % util.hidepassword(dest))
2153 2153 if revs:
2154 2154 revs = [repo.lookup(rev) for rev in revs]
2155 r = repo.push(other, opts['force'], revs=revs)
2155 r = repo.push(other, opts.get('force'), revs=revs)
2156 2156 return r == 0
2157 2157
2158 2158 def rawcommit(ui, repo, *pats, **opts):
@@ -2173,7 +2173,7 b' def rawcommit(ui, repo, *pats, **opts):'
2173 2173 message = cmdutil.logmessage(opts)
2174 2174
2175 2175 files = cmdutil.match(repo, pats, opts).files()
2176 if opts['files']:
2176 if opts.get('files'):
2177 2177 files += open(opts['files']).read().splitlines()
2178 2178
2179 2179 parents = [repo.lookup(p) for p in opts['parent']]
@@ -2342,15 +2342,15 b' def revert(ui, repo, *pats, **opts):'
2342 2342 raise util.Abort(_("you can't specify a revision and a date"))
2343 2343 opts["rev"] = cmdutil.finddate(ui, repo, opts["date"])
2344 2344
2345 if not pats and not opts['all']:
2345 if not pats and not opts.get('all'):
2346 2346 raise util.Abort(_('no files or directories specified; '
2347 2347 'use --all to revert the whole repo'))
2348 2348
2349 2349 parent, p2 = repo.dirstate.parents()
2350 if not opts['rev'] and p2 != nullid:
2350 if not opts.get('rev') and p2 != nullid:
2351 2351 raise util.Abort(_('uncommitted merge - please provide a '
2352 2352 'specific revision'))
2353 ctx = repo[opts['rev']]
2353 ctx = repo[opts.get('rev')]
2354 2354 node = ctx.node()
2355 2355 mf = ctx.manifest()
2356 2356 if node == parent:
@@ -2432,7 +2432,7 b' def revert(ui, repo, *pats, **opts):'
2432 2432 target = repo.wjoin(abs)
2433 2433 def handle(xlist, dobackup):
2434 2434 xlist[0].append(abs)
2435 if dobackup and not opts['no_backup'] and util.lexists(target):
2435 if dobackup and not opts.get('no_backup') and util.lexists(target):
2436 2436 bakname = "%s.orig" % rel
2437 2437 ui.note(_('saving current version of %s as %s\n') %
2438 2438 (rel, bakname))
@@ -2653,11 +2653,11 b' def status(ui, repo, *pats, **opts):'
2653 2653
2654 2654 node1, node2 = cmdutil.revpair(repo, opts.get('rev'))
2655 2655 cwd = (pats and repo.getcwd()) or ''
2656 end = opts['print0'] and '\0' or '\n'
2656 end = opts.get('print0') and '\0' or '\n'
2657 2657 copy = {}
2658 2658 states = 'modified added removed deleted unknown ignored clean'.split()
2659 2659 show = [k for k in states if opts[k]]
2660 if opts['all']:
2660 if opts.get('all'):
2661 2661 show += ui.quiet and (states[:4] + ['clean']) or states
2662 2662 if not show:
2663 2663 show = ui.quiet and states[:4] or states[:5]
@@ -2666,7 +2666,7 b' def status(ui, repo, *pats, **opts):'
2666 2666 'ignored' in show, 'clean' in show, 'unknown' in show)
2667 2667 changestates = zip(states, 'MAR!?IC', stat)
2668 2668
2669 if (opts['all'] or opts['copies']) and not opts['no_status']:
2669 if (opts.get('all') or opts.get('copies')) and not opts.get('no_status'):
2670 2670 ctxn = repo[nullid]
2671 2671 ctx1 = repo[node1]
2672 2672 ctx2 = repo[node2]
@@ -2683,7 +2683,7 b' def status(ui, repo, *pats, **opts):'
2683 2683 for state, char, files in changestates:
2684 2684 if state in show:
2685 2685 format = "%s %%s%s" % (char, end)
2686 if opts['no_status']:
2686 if opts.get('no_status'):
2687 2687 format = "%%s%s" % end
2688 2688
2689 2689 for f in files:
@@ -2719,13 +2719,13 b' def tag(ui, repo, name1, *names, **opts)'
2719 2719 for n in names:
2720 2720 if n in ['tip', '.', 'null']:
2721 2721 raise util.Abort(_('the name \'%s\' is reserved') % n)
2722 if opts['rev'] and opts['remove']:
2722 if opts.get('rev') and opts.get('remove'):
2723 2723 raise util.Abort(_("--rev and --remove are incompatible"))
2724 if opts['rev']:
2724 if opts.get('rev'):
2725 2725 rev_ = opts['rev']
2726 message = opts['message']
2727 if opts['remove']:
2728 expectedtype = opts['local'] and 'local' or 'global'
2726 message = opts.get('message')
2727 if opts.get('remove'):
2728 expectedtype = opts.get('local') and 'local' or 'global'
2729 2729 for n in names:
2730 2730 if not repo.tagtype(n):
2731 2731 raise util.Abort(_('tag \'%s\' does not exist') % n)
@@ -2735,7 +2735,7 b' def tag(ui, repo, name1, *names, **opts)'
2735 2735 rev_ = nullid
2736 2736 if not message:
2737 2737 message = _('Removed tag %s') % ', '.join(names)
2738 elif not opts['force']:
2738 elif not opts.get('force'):
2739 2739 for n in names:
2740 2740 if n in repo.tags():
2741 2741 raise util.Abort(_('tag \'%s\' already exists '
@@ -2753,7 +2753,7 b' def tag(ui, repo, name1, *names, **opts)'
2753 2753 if date:
2754 2754 date = util.parsedate(date)
2755 2755
2756 repo.tag(names, r, message, opts['local'], opts['user'], date)
2756 repo.tag(names, r, message, opts.get('local'), opts.get('user'), date)
2757 2757
2758 2758 def tags(ui, repo):
2759 2759 """list repository tags
@@ -2823,7 +2823,7 b' def unbundle(ui, repo, fname1, *fnames, '
2823 2823 finally:
2824 2824 del lock
2825 2825
2826 return postincoming(ui, repo, modheads, opts['update'], None)
2826 return postincoming(ui, repo, modheads, opts.get('update'), None)
2827 2827
2828 2828 def update(ui, repo, node=None, rev=None, clean=False, date=None):
2829 2829 """update working directory
General Comments 0
You need to be logged in to leave comments. Login now