Commit Graph

5227 Commits

Author SHA1 Message Date
Alexis S. L. Carvalho
714fa94597 Merge with crew-stable 2007-08-27 02:21:58 -03:00
Alexis S. L. Carvalho
420ceda070 avoid double slash problem mentioned in issue695 2007-08-27 01:44:35 -03:00
Alexis S. L. Carvalho
b7234419e2 clone: remove "file://" before making the path absolute
This avoids writing bogus paths to .hgrc.  Fixes issue695.
2007-08-27 01:44:35 -03:00
Alexis S. L. Carvalho
73454f8d16 pull -u: if "url#rev" was given, update to rev 2007-08-27 01:44:35 -03:00
Alexis S. L. Carvalho
616367be9a clone: if "url#rev" was given, update to rev 2007-08-27 01:44:35 -03:00
Alexis S. L. Carvalho
88d2731fa8 parseurl: also return the revision after the "#"; add a test 2007-08-27 01:44:35 -03:00
Alexis S. L. Carvalho
1e3fbe3765 pull -r: pass the revisions as the heads argument of findincoming
This can make a hg pull -r faster if the remote repo has many heads,
and fixes an "abort: received changelog group is empty".
2007-08-27 01:44:35 -03:00
Patrick Mezard
c9e8914a18 Merge with crew-stable 2007-08-26 19:13:24 +02:00
Patrick Mezard
e0104ee85f convert: fix /dev/null redirections under Windows 2007-08-26 19:05:19 +02:00
Patrick Mezard
5d54b971c7 Merge with crew-stable 2007-08-26 16:49:26 +02:00
Patrick Mezard
26ffa26890 Test git repository conversion 2007-08-26 15:07:13 +02:00
Patrick Mezard
ce0d9a3c84 hghave: detect git availability 2007-08-26 15:35:57 +02:00
Patrick Mezard
6202bc3003 convert: fix issue702 about GIT_DIR= construct unsupported under Windows. 2007-08-26 14:51:27 +02:00
Brendan Cully
6c3736cbca Improve extdiff configuration.
In addition to the old cmd.foo, opts.foo hgrc entries, allow a more simple
alias = command [opts]... form. For example:
[extdiff]
cdiff = colordiff -uprN
2007-08-25 12:25:53 -07:00
Benoit Boissinot
6addb45a89 cgi: sys.path.insert should be before importing mercurial
thanks to R. Burke
2007-08-25 16:31:37 +02:00
Benoit Boissinot
1c8a89a5a7 merge with crew 2007-08-25 11:30:59 +02:00
Benoit Boissinot
513ea49cfc improve error message for 'hg merge' when repo already at branchtip 2007-08-25 11:30:11 +02:00
Brendan Cully
737a6eca37 imerge: add automerge flag to attempt to batch merge all conflicts 2007-08-23 22:45:41 -07:00
Brendan Cully
41c866722b Merge with crew 2007-08-23 19:52:15 -07:00
Brendan Cully
671f6fd2a7 imerge: fix ancestor calculation
If wctx already has two parents, ancestor calculation is wrong.
Normally merge is called before wctx gets the second parent, so
we simulate this in imerge by temporarily popping the second parent
before calling filemerge. Highly dirty.

This patch also handles the ParseError move from cmdutil to dispatch.
2007-08-23 19:51:59 -07:00
Benoit Boissinot
db7ad2ab70 merge with crew-stable 2007-08-24 00:56:56 +02:00
Benoit Boissinot
b884c9144e fix test-permissions output 2007-08-24 00:56:08 +02:00
Benoit Boissinot
e52485e94a merge with crew-stable 2007-08-24 00:53:16 +02:00
Benoit Boissinot
cfb5e37845 testcase for issue705 (fixed by 739cbeba775b) 2007-08-24 00:52:28 +02:00
Benoit Boissinot
6c80bb0bbe merge with crew-stable 2007-08-24 00:39:59 +02:00
Benoit Boissinot
0d54a05da3 merge with -stable 2007-08-24 00:39:16 +02:00
Benoit Boissinot
f71cd2e266 check exec: return fallback in case of error during the check
If there is any error while checking if exec is supported,
we can return fallback.
fix issue705
2007-08-24 00:38:08 +02:00
Brendan Cully
461732b80c mq: some improvements to header rewriting (closes #690)
Tested with qrefresh -m against the mm series.
2007-08-23 13:59:52 -07:00
Brendan Cully
1e7be967ee Merge with crew-stable 2007-08-23 12:24:54 -07:00
Brendan Cully
ea30b97aed Do not lose previous tags when adding a tag in raw mode 2007-08-23 12:23:07 -07:00
Alexis S. L. Carvalho
a345c2c9da merge: forcefully mark files that we get from the second parent as dirty
After a hg merge, we want to include in the commit all the files that we
got from the second parent, so that we have the correct file-level
history.  To make them visible to hg commit, we try to mark them as dirty.

Unfortunately, right now we can't really mark them as dirty[1] - the
best we can do is to mark them as needing a full comparison of their
contents, but they will still be considered clean if they happen to be
identical to the version in the first parent.

This changeset extends the dirstate format in a compatible way, so that
we can mark a file as dirty:

Right now we use a negative file size to indicate we don't have valid
stat data for this entry.  In practice, this size is always -1.

This patch uses -2 to indicate that the entry is dirty.  Older versions
of hg won't choke on this dirstate, but they may happily mark the file
as clean after a full comparison, destroying all of our hard work.

The patch adds a dirstate.normallookup method with the semantics of the
current normaldirty, and changes normaldirty to forcefully mark the
entry as dirty.

This should fix issue522.

[1] - well, we could put them in state 'm', but that state has a
different meaning.
2007-08-23 01:48:29 -03:00
Matt Mackall
73411dd185 gendoc: use demandimport 2007-08-20 21:10:45 -05:00
Matt Mackall
c3fd750ce3 Merge with -crew 2007-08-20 21:14:53 -05:00
Benoit Boissinot
13bbfcaf55 make hg add of a removed file unremove the file
if a file was removed, hg add shouldn't mark the file
as added, but as normal

see issue683
2007-08-21 02:13:32 +02:00
Benoit Boissinot
b71f9f2bbf abort when adding a file in merged state 2007-08-21 02:02:08 +02:00
rupert.thurner@gmail.com
8e267a0e78 add import from url capability 2007-08-20 22:02:05 +02:00
Matt Mackall
dbef99a2d7 Merge with -stable 2007-08-19 14:04:26 -05:00
Matt Mackall
0bcff0f870 match: handle large regexes
Some Python versions don't handle large regexes, so when we hit an
overflow, split our regex in two.
2007-08-19 14:03:56 -05:00
Patrick Mezard
e2a0f6645e convert: load parent commits on-demand 2007-08-19 17:38:40 +02:00
Patrick Mezard
f5be1652a3 convert: wrap cached commits author remapping 2007-08-19 17:38:07 +02:00
Alexis S. L. Carvalho
3b929dfbb5 path_auditor: cache names of audited directories
We use a separate cache to avoid problems with

audit = path_auditor(repo.root)
audit("subrepo")
audit("subrepo/file")

whitelisting "subrepo" (which is fine) and then using the same whitelist
with "subrepo/file" (which is not fine).

Since we create a separate path_auditor for every path on the command line,
a "hg add dir/a dir/b dir/c" will still lstat dir 3 times just to audit
the paths.
2007-08-18 21:36:10 -03:00
Thomas Arendsen Hein
2f533bf4a6 Quote ^ and ~ chars in test-parentrevspec.
At least ^ causes problems on some sh implementations.
2007-08-18 20:21:14 +02:00
Alexis S. L. Carvalho
d11dad17a3 Remove demandimport.enable from dispatch.py 2007-08-18 14:25:55 -03:00
Thomas Arendsen Hein
90d76a6ec9 Enable demandimport only in scripts, not in importable modules (issue605)
This way other applications can choose if and when they want this feature,
because it might be problematic if those applications rely on ImportError.
2007-08-18 11:37:08 +02:00
Alexis S. L. Carvalho
1ee06d75a7 Merge with crew-stable 2007-08-17 23:20:13 -03:00
Alexis S. L. Carvalho
11336d4a94 Fix sshrepo.unbundle
We weren't reading all the data sent by the server.  Depending on
the system, the remote hg (actually, the remote python) could send a
"close failed: [Errno 32] Broken pipe", making some tests fail.
2007-08-17 22:43:38 -03:00
Alexis S. L. Carvalho
de2d9c54e8 run-tests.py: pass --install-scripts to setup.py
This avoids possible problems when the user has a ~/.pydistutils.cfg.
Fixes issue638.  Patch provided by Ralf Schmitt.
2007-08-17 22:43:38 -03:00
Peter Meerwald
263e23ecf3 recognize user:password in URLs that include port numbers.
when giving user/pwd in an URL, eg.
hg pull http://user:pwd@host.com:666/hg/something,
hg would still ask for user/pwd in interactive mode (or fail in
non-interactive)
2007-08-17 22:43:38 -03:00
Alexis S. L. Carvalho
d999b43c2b convert: fix mercurial_sink.putcommit
Changeset 31be2f4d36a5 added some code to putcommit to avoid creating a
revision that touches no files, but this can break regular conversions
from some repositories:

- conceptually, since we're converting a repo, we should try to make
  the new hg repo as similar as possible to the original repo - we
  should create a new changeset, even if the original revision didn't
  touch any files (maybe the commit message had some important bit);

- even if a "regular" revision that doesn't touch any file may seem
  weird (and maybe even broken), it's completely legitimate for a merge
  revision to not touch any file, and, if we just skip it, the
  converted repo will end up with wrong history and possibly an extra
  head.

  As an example, say the crew and main hg repos are sync'ed.  Somebody
  sends an important patch to the mailing list.  Matt quickly applies
  and pushes it.  But at the same time somebody also applies it to crew
  and pushes it.  Suppose the commit message ended up being a bit
  different (say, there was a typo and somebody didn't fix it) or that
  the date ended up being different (because of different patch-applying
  scripts): the changeset hashes will be different, but the manifests
  will be the same.

  Since both changesets were pushed to public repos, it's hard to recall
  them.  If both are merged, the manifest from the resulting merge
  revision will have the exact same contents as its parents - i.e. the
  merge revision really doesn't touch any file at all.

To keep the file filtering stuff "working", the generic code was changed
to skip empty revisions if we're filtering the repo, fixing a bug in the
process (we want parents[0] instead of tip).
2007-08-17 20:18:05 -03:00
Alexis S. L. Carvalho
e60e53981a Add parentrevspec extension 2007-08-17 17:33:27 -03:00