Commit Graph

1740 Commits

Author SHA1 Message Date
Martin Geisler
ec0bf03276 Merge with stable 2010-08-15 18:13:46 +02:00
Martin Geisler
90ff407862 debugbuilddag: escape backslash properly in help string 2010-08-15 17:33:03 +02:00
Greg Ward
b38d220736 commit: explicitly document the existence of "last-message.txt" 2010-08-14 14:57:33 +02:00
Martin Geisler
fb68103f19 Merge with stable 2010-08-13 10:28:59 +02:00
Mark Edgington
f3ee05373b resolve: updated help documentation for improved clarity 2010-08-12 22:48:22 +02:00
Martin Geisler
c3f9a46ceb Merge with stable 2010-08-11 12:30:18 +02:00
Martin Geisler
eeae22999b commands: use round parenthesis in 'hg head --active' help
This is the style used in the rest of the help strings.
2010-08-11 12:21:27 +02:00
Matt Mackall
9cc346f0b4 help: fix bytes/digit confusion for hashes
spotted by FUJIWARA Katsunori <fujiwara@ascade.co.jp>
2010-07-31 18:27:03 -05:00
Matt Mackall
272a0b3fc3 Merge with stable 2010-07-27 16:04:00 -05:00
Benjamin Pollack
728f9bcc7e tag: do not allow tag names to consist solely of whitespace (issue2307)
(simplification and test by mpm)
2010-07-27 14:40:25 -04:00
Patrick Mezard
14211b6209 debugbuilddag: build repository content in binary mode 2010-07-26 23:26:15 +02:00
Nicolas Dumazet
7a95a27065 bundle: lookup revisions after addbranchrevs
When addbranchrevs extends revs, it adds changeset hashes, and not node ids.
Which means that we have to lookup for revisions _after_ the addbranchrevs
call, instead of before.
2010-07-20 18:29:00 +09:00
Mads Kiilerich
b098dc8c48 revert: rename original to .orig instead of copying (issue2282)
By renaming before reverting the content of the file we ensure that we handle
and break hardlinks properly.

Handling of other hardlinks to .orig is somebody elses problem.
2010-07-13 03:04:14 +02:00
Steve Losh
aaac1bb52d commands: fix update's help to be more accurate
Branches can have multiple heads, so it doesn't make sense to speak of "the
head of the current branch". What update really does is try to update to the
*tip* of the current branch.
2010-07-14 18:28:12 -04:00
FUJIWARA Katsunori
2f9dbb12f7 i18n: use encoding.colwidth() for correct column width
Some encoding and language combinations (e.g.: UTF-8 and Japanese)
cause encoding characters into sequence of bytes more than column
width of them.

So, encoding.colwidth() should be applied instread of len() on i18n
strings.

In addition to it, formatting by '%*s'/'%-*s' also uses "number of
bytes" to calculate space padding size, and should be fixed, too.
2010-07-18 01:06:50 +09:00
Nicolas Dumazet
517eb64655 merge with stable 2010-07-22 15:14:22 +09:00
Matt Mackall
33994da433 Merge with stable 2010-07-20 15:07:10 -05:00
Martin Geisler
7f537e599c Merge with stable 2010-07-19 00:43:34 +02:00
Martin Geisler
138130c348 archival: move commands.archive.guess_type to archival.guesskind
The list of suffixes for each kind of archive belongs in archival.
Renamed function to fit with out code style.
2010-07-14 20:25:31 +02:00
Dirkjan Ochtman
e647af81b9 commands: addremove does similarity 100 by default 2010-07-13 17:30:29 +02:00
Martin Geisler
5fbbb27c25 Merge with stable 2010-07-09 14:21:45 +02:00
Arnab Bose
a9ac0e99d7 commands: mention "hg status -C" in addremove help 2010-07-09 13:31:37 +02:00
Steve Losh
c2cf2592b2 dispatch: add shell aliases
This patch adds git-style "shell aliases" to Mercurial.

Any alias with a definition beginning with a '!' will be treated as a shell
alias. For example:

    [alias]
    echo = !echo
    qempty = !hg qrefresh -X "`hg root`" ; echo Emptied patch "`hg qtop`"

    $ hg echo foo
    foo
    $ hg qempty
    Emptied patch foo
    $
2010-07-07 18:49:43 -04:00
Robert Bauck Hamar
d6a84c6ef2 commands: only warn when reopening the workdir's branch
When commiting, a check is made to see if one of the parents is a
closed head. However this did not check that the branch of the commit
is the same as the closed head, so one could get a warning message on
the sequence

  hg commit --close-branch
  hg branch new-branch
  hg commit

or when merging in a closed head.
2010-07-07 14:11:59 +02:00
Yuya Nishihara
910c40b6b6 log: fix missing diff output for hg log -p in sub directory
prep(ctx, fns) receives paths relative to repository root, not cwd.
2010-07-02 23:49:06 +09:00
Nicolas Dumazet
1624d50ea1 commands: document return values of add and paths commands 2010-07-04 17:05:17 +09:00
Mads Kiilerich
812bb21f4d log: follow filenames through renames (issue647)
In commands.log a displayer was initialized from
cmdutil.show_changeset() with the initial matchfn (which designates
the specified files which only is correct in the highest revision in
the range). prep() is handed the correct list of files, but
displayer.show() didn't use that list but keept using the original
matchfn.

The matchfn argument to cmdutil.show_changeset() wasn't specified in
other places and is only used in .show(), so now we give the matchfn
as an optional parameter to .show().

We do however still have to detect --patch and --stat from opts in
show_changeset() and let it imply a matchall, but that can now be
overruled with the new .show() matchfn parameter.
2010-06-29 12:12:34 +02:00
Mads Kiilerich
07f64c28d2 revert: Make it clearer when not to use revert 2010-06-28 15:08:01 +02:00
Matt Mackall
5c92f50408 merge: document how to 'undo' a merge 2010-06-27 17:41:43 -05:00
Matt Mackall
e4cf775b71 addchangegroup: pass in lock to release it before changegroup hook is called
Currently, callers of addchangegroup first acquire the repository
lock, usually to check that an unbundle request isn't racing. This
means that changegroup hook actions that might write to a repo get
stuck waiting for a lock. Here, we add a new optional lock parameter
and update all the callers. Post-1.6 we may make it non-optional.
2010-06-25 13:47:28 -05:00
Martin Geisler
547f89d8a5 commands: advertise "hg help revsets" in help for log 2010-06-18 21:35:21 +02:00
Matt Mackall
3902a6d8f6 pushkey: add debugpushkey command for testing 2010-06-16 16:05:47 -05:00
Greg Ward
20b557f443 merge: when current branch has 1 or > 2 heads, actually abort.
Currently merge just prints abort-like messages to stderr and then
exits with a misleading status 0 (cleverly disguised as "False").
With this change it raises Abort, just like every other fatal error.
2010-06-14 16:06:52 -04:00
Martin Geisler
e996783e84 commands: get rid of generic exception in debugbuilddag 2010-06-15 09:53:50 +02:00
Martin Geisler
96576cd383 commands: format is a Python2.6 function 2010-06-11 18:54:10 +02:00
Peter Arrenbrecht
b9ce7f49a5 debugbuilddag: build a changelog dag from a concise description
Useful in tests to quickly build a complex DAG in an empty repo.
Handles local tags and named branches.
Options to, at each rev,
 - create a new file,
 - overwrite the same file,
 - append to the same file,
 - write to a specific line in a mergeable file.
Can run shell commands during DAG buildup.
2010-06-10 11:49:48 +02:00
Peter Arrenbrecht
a9d00c7c41 debugdag and debugindexdag: emit changelog/revlog DAGs as concise text
Mainly useful for reusing DAGs somewhere else, for example for attaching
them to a bug report, or for importing them into other environments
(like my test environment for incoming/outgoing discovery).
2010-06-10 11:48:45 +02:00
Matt Mackall
1cf1295d6e summary: report copies and renames 2010-06-09 16:39:25 -05:00
FUJIWARA Katsunori
ce06b102df help: show value requirement and multiple occurrence of options
this helps users to know what kind of option is:

  - no value is required(flag option)
  - value is required
  - value is required, and multiple occurrences are allowed

each kinds are shown as below:

 -f --force              force push
 -e --ssh CMD            specify ssh command to use
 -b --branch BRANCH [+]  a specific branch you would like to push

if one or more 3rd type options are shown, explanation for '[+]' mark
is also shown as footnote.
2010-06-06 17:25:00 +09:00
Gilles Moris
54d30f05ab commit: fix display of 'created new head' message (issue2186)
To avoid recurrent fixes for the display of this message, a summary table with
all case combinations has been added to the code.
Basically, there is two condition for the message to be printed:
* this is not an initial (named branch or topo) root
* none of the parents are in the current branch heads
2010-06-08 22:28:42 +02:00
Steve Borho
0d0e614fc9 Merge backout 2010-06-08 15:52:56 -05:00
Steve Borho
b82bd4f289 Backed out changeset: 1bfde817782c 2010-06-08 15:52:41 -05:00
Dirkjan Ochtman
af6b696f0f move working dir/dirstate methods from localrepo to workingctx 2010-06-07 20:03:32 +02:00
Steve Borho
e91613380a color: labeled text should be passed to ui.write() as ui.labeled
Some implementations of ui.label() (HTML versions in particular) must escape
the provided text and then markup the text with their tags.  When this marked
up text is then passed to ui.write(), we must label the text as 'ui.labeled'
so the implementation knows not to escape it a second time (exposing the initial
markup).

This required the addition of a 'ui.plain' label for text that is purposefully
not marked up.

I was a little pedantic here, passing even ' ' strings to ui.label() when it
would be included with other labeled text in a ui.write() call.   But it seemed
appropriate to lean to the side of caution.
2010-06-03 23:18:18 -05:00
Dirkjan Ochtman
cf1de649bd move discovery methods from localrepo into new discovery module 2010-06-07 18:35:54 +02:00
FUJIWARA Katsunori
9cce255bec replace Python standard textwrap by MBCS sensitive one for i18n text
Mercurial has problem around text wrapping/filling in MBCS encoding
environment, because standard 'textwrap' module of Python can not
treat it correctly. It splits byte sequence for one character into two
lines.

According to unicode specification, "east asian width" classifies
characters into:

   W(ide), N(arrow), F(ull-width), H(alf-width), A(mbiguous)


W/N/F/H can be always recognized as 2/1/2/1 bytes in byte sequence,
but 'A' can not. Size of 'A' depends on language in which it is used.

Unicode specification says:

   If the context(= language) cannot be established reliably they
   should be treated as narrow characters by default

but many of class 'A' characters are full-width, at least, in Japanese
environment.

So, this patch treats class 'A' characters as full-width always for
safety wrapping.

This patch focuses only on MBCS safe-ness, not on writing/printing
rule strict wrapping for each languages

MBCS sensitive textwrap class is originally implemented
by ITO Nobuaki <daydream.trippers@gmail.com>.
2010-06-06 17:20:10 +09:00
Matt Mackall
a1c4034fda revset: add a debugrevspec command 2010-06-01 11:18:57 -05:00
Matt Mackall
86ebd43d71 remoteui: move from cmdutil to hg 2010-06-01 11:18:57 -05:00
Martin Geisler
02f8de2883 commands: document --new-branch flag for push 2010-05-25 09:57:19 +02:00
Martin Geisler
c5e5ad33a2 Merge with stable 2010-05-25 09:56:26 +02:00