Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/commands.py @ 354:e3667e3a18ac
hg commit: add -A flag
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
hg commit: add -A flag
From: Chris Mason <mason@suse.com>
Add hg commit -A that calls hg addremove before trying to run the commit
manifest hash: d25cb3ab4e0dc2e8642bcbef32da4ab178cd4823
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCsGzrywK+sNU5EO8RAvdFAJ46ZjyACMvKEUq8RmdxZB9ZE0z6ygCfYYzq
UP2EXTOQ2pdhxKFyad8h/Rg=
=wzZD
-----END PGP SIGNATURE-----
author | mpm@selenic.com |
---|---|
date | Wed, 15 Jun 2005 10:01:15 -0800 |
parents | dda243bb34b3 |
children | 3e18360a8912 |
comparison
equal
deleted
inserted
replaced
353:dda243bb34b3 | 354:e3667e3a18ac |
---|---|
244 text = opts['text'] | 244 text = opts['text'] |
245 if not text and opts['logfile']: | 245 if not text and opts['logfile']: |
246 try: text = open(opts['logfile']).read() | 246 try: text = open(opts['logfile']).read() |
247 except IOError: pass | 247 except IOError: pass |
248 | 248 |
249 if opts['addremove']: | |
250 addremove(ui, repo, *files) | |
249 repo.commit(relpath(repo, files), text, opts['user'], opts['date']) | 251 repo.commit(relpath(repo, files), text, opts['user'], opts['date']) |
250 | 252 |
251 def debugaddchangegroup(ui, repo): | 253 def debugaddchangegroup(ui, repo): |
252 data = sys.stdin.read() | 254 data = sys.stdin.read() |
253 repo.addchangegroup(data) | 255 repo.addchangegroup(data) |
594 ('c', 'changeset', None, 'show changeset')], | 596 ('c', 'changeset', None, 'show changeset')], |
595 'hg annotate [-u] [-c] [-n] [-r id] [files]'), | 597 'hg annotate [-u] [-c] [-n] [-r id] [files]'), |
596 "cat|dump": (cat, [], 'hg cat <file> [rev]'), | 598 "cat|dump": (cat, [], 'hg cat <file> [rev]'), |
597 "commit|ci": (commit, | 599 "commit|ci": (commit, |
598 [('t', 'text', "", 'commit text'), | 600 [('t', 'text', "", 'commit text'), |
601 ('A', 'addremove', None, 'run add/remove during commit'), | |
599 ('l', 'logfile', "", 'commit text file'), | 602 ('l', 'logfile', "", 'commit text file'), |
600 ('d', 'date', "", 'data'), | 603 ('d', 'date', "", 'data'), |
601 ('u', 'user', "", 'user')], | 604 ('u', 'user', "", 'user')], |
602 'hg commit [files]'), | 605 'hg commit [files]'), |
603 "debugaddchangegroup": (debugaddchangegroup, [], 'debugaddchangegroup'), | 606 "debugaddchangegroup": (debugaddchangegroup, [], 'debugaddchangegroup'), |