Commit Graph

17179 Commits

Author SHA1 Message Date
Pierre-Yves David
3fa4ff72f7 obsolete: move obsolete markers read/write logic to obsstore object
This is the first step toward incremental writing of obsolete marker within a
transaction.

For this purpose, obsstore is now given its repo sopener. This make it able to
handles read and write to the obsstore file itself. Most IO logic is removed
from localrepo and handled by obsstore object directly.
2012-07-04 02:00:36 +02:00
Matt Mackall
b02cfbb12b debugobsolete: remove spurious ctx from variable name
'contexts' are objects like the ones described in context.py, not
anything that describes a situation.
2012-07-11 18:35:14 -05:00
Idan Kamara
bcb7450401 amend: disable hooks when creating intermediate commit (issue3501) 2012-06-23 19:57:29 +03:00
Idan Kamara
7875dccb0b ui: add a variable to control whether hooks should be called
So hooks can be temporarily disabled.
2012-06-23 19:57:07 +03:00
Pierre-Yves David
49188ab1f7 strip: update help to state than you can strip public changeset
Multiple people have been confused by it.
2012-06-28 18:39:16 +02:00
David Schleimer
de4c701f51 bookmarks: correctly update current bookmarks on rebase (issue2277)
When you rebased with a currently active bookmark, that bookmark would
always point at the new tip, regardless of what revision it pointed at
before the rebase.

All bookmarks will now point at the equivalent post-rebase commit.
However, the currently active bookmark will cease to be active unless
it points at the new tip post-rebase.  Rebase will always leave the
new tip as the working copy parent, which is incompatible with having
an active bookmark that points at some other revision.  The common
case should be that the active bookmark will point at the new tip
post-rebase.
2012-06-22 11:40:31 -07:00
Wagner Bruna
9ee135f30f i18n-pt_BR: synchronized with 9e1c386d48be 2012-06-22 10:19:56 -03:00
Wagner Bruna
20ecdc31fe merge with i18n 2012-06-22 10:14:21 -03:00
Pierre-Yves David
d4f8bfb950 discovery: simplify branchmap construction against legacy server
All necessary data to fire a simple revset query are already known. No call to
ancestors are needed. Such ancestors calculation was already done to compute
outgoing.missing.
2012-06-22 12:17:49 +02:00
Matt Mackall
cbbdbdd866 copies: re-include root directory in directory rename detection (issue3511) 2012-06-27 13:41:04 -05:00
Bryan O'Sullivan
47b1cf0c50 store: sort filenames in place 2012-06-25 15:14:05 -07:00
Mads Kiilerich
278667f10c convert: check for failed svn import in debugsvnlog and abort cleanly
'hg debugsvnlog' failed with a crash when using the uninitialized transport in
get_log_child if the import of the svn libraries had failed.

'convert' should never get as far as launching 'hg debugsvnlog' if the svn
libraries are missing, but by launching a subprocess there is risk that the
environment is mangled so the second import fails.

It is in principle also possible to launch the command manually.
2012-06-29 01:51:48 +02:00
Mads Kiilerich
37140b89be convert: accept Subversion 'file:///c%3A/svnrepo' syntax on Windows
Subversion can handle ':' quoted as '%3A' but urllib.url2pathname can't and
Mercurial thus rejected some valid subversions URLs.

This particular case will now be handled by some preprocessing before handing
it over to urllib.url2pathname.

This is tested by a0c992a723f9 when test-convert-svn-source.t and
test-convert-svn-move.t can be run on Windows.
2012-06-28 03:41:37 +02:00
Adrian Buehlmann
bc646a116e win32: remove uneeded usage of _STARTF_USESHOWWINDOW
spawndetached() was the only user of _STARTF_USESHOWWINDOW and it creates the
process with _CREATE_NO_WINDOW anyway. If the process has no window, then
there is nothing to hide.
2012-06-25 19:26:29 +02:00
Adrian Buehlmann
d8571d886c win32: specify _CREATE_NO_WINDOW on spawndetached()
Before this change, a console window briefly popped up on "hg serve -d" and
disappeared again, stealing the focus window (which was very annyoing when
running tests).

Specifying _CREATE_NO_WINDOW instead of _DETACHED_PROCESS fixes this (as tested
on Windows 7 x64).
2012-06-25 19:11:29 +02:00
Mads Kiilerich
b4bee4c024 tests: add missing path globbing for Windows in svn tests 2012-06-27 02:34:58 +02:00
Sune Foldager
77ac86c2b5 fix push of moved bookmark when creating new branch heads
The problem occured when pushing a changeset that at the same time creates a
new named branch head and moves a bookmark. The code invoked methods that only
exist on localrepo instances, so it failed for any other type of remote. The
test suite only tested against local remotes.
2012-06-26 23:05:25 +02:00
Matt Mackall
4a2b436e62 merge with stable 2012-06-26 15:08:10 -05:00
Bryan O'Sullivan
4bb35317bc scmutil: speed up new-style range extension
This improves perfrevset performance by 10% for 2222::33333 on a
kernel repo.
2012-06-22 12:00:41 -07:00
Thomas Arendsen Hein
bbd22fd92b merge with crew-stable 2012-06-26 14:32:20 +02:00
Mads Kiilerich
b584158b6d tests: cleanup of svn url handling
The subversion tests used different tricks to create properly encoded URLs,
partly due to partial support for different ways of running the tests on
windows. Now we only need/support one way of running the tests on windows.

Windows URLs should look like 'file:///c:/foo%20bar' and on Unix platforms
like 'file:///tmp/baz'.

'pwd' in the test framework will on Windows emit paths like 'c:/foo bar'.
Explicit handling of backslashes in paths is thus no longer needed and is
removed.  Paths on windows do however need an extra '/' compared to other
platforms.

This change makes test-subrepo-svn.t pass on windows with msys. Other tests
might need more work.
2012-06-26 03:35:22 +02:00
Eduard-Cristian Stefan
171e65bf7f test-subrepo-svn.t: partially adapt for Windows
hg forget 'notafile*' is changed to use a name that is valid on Windows so we
still get the same error ... but the error message is disabled because it
varies with the Windows version.
2012-06-23 19:54:08 +03:00
Mads Kiilerich
f9f38dc7f8 convert: ignore svn:executable for subversion targets without exec bit support
Calling propset/propdel with subversion 1.6 on FAT gave
  abort: svn exited with status 256
and made test-convert-hg-svn.t and test-convert-svn-sink.t fail. 1.7 worked.

This is a rework of 5ba59c098f03 but ignores the executable bit when it isn't
supported instead of using an approximation.
2012-06-24 17:06:47 +02:00
Mads Kiilerich
c6829a39d5 tests: add missing 'backup bundle' path glob in test-rebase-collapse.t
Introduced by f071275fac59.
2012-06-22 02:39:52 +02:00
Mads Kiilerich
ebd808f364 tests: add missing 'backup bundle' path glob in test-rebase-scenario-global.t
Introduced by d13aaf5669b3.
2012-06-22 00:52:14 +02:00
Matt Mackall
36aa7282e4 merge with crew 2012-06-21 17:37:02 -05:00
Martin Schröder
6b5b6e7367 i18n-de: Move policies from header of de.po to http://mercurial.selenic.com/wiki/GermanTranslation 2012-06-21 18:23:18 +02:00
Martin Geisler
d22efb8f52 merge with stable 2012-06-21 15:10:01 +02:00
Adrian Buehlmann
41fcaa827d test-http and test-https: partially adapt for Windows 2012-06-19 19:45:00 +02:00
Eduard-Cristian Stefan
bdebec155d test-subrepo-git.t: adapt for Windows
hg forget 'notafile*' is changed to use a name that is valid on Windows so we
still get the same error ... but the error message is disabled because it
varies with the Windows version.
2012-06-20 02:09:49 +03:00
Adrian Buehlmann
938a48ede9 test-bookmarks-pushpull: partially adapt for Windows
The kill call at the end is redundant, as we already have

199:  $ hg serve -p $HGPORT -d --pid-file=../hg.pid -E errors.log
200:  $ cat ../hg.pid >> $DAEMON_PIDS

So there is nothing left that would not already be killed by the $DAEMON_PIDS
mechanism.
2012-06-20 18:02:01 +02:00
Adrian Buehlmann
af62deef88 test-static-http: partially adapt for Windows 2012-06-19 19:28:55 +02:00
Adrian Buehlmann
2b98836d65 test-bad-pull: partially adjust for Windows
On a English Windows 7, the testcase fails with

  $ hg clone http://localhost:$HGPORT/ copy
  abort: error: No connection could be made because the target machine actively refused it

Since the error message on non-English Windows installs are most likely
different, we have to glob the entire error message away for Windows.
2012-06-19 17:05:04 +02:00
Mads Kiilerich
a8107f523f tests: consistently use printenv.py the same MSYS/Windows-compatible way
This will remove some reasons some tests are disabled on Windows.
2012-06-21 03:05:02 +02:00
Mads Kiilerich
1fda0b1af1 tests: prepare get-with-headers.py for MSYS
get-with-headers.py took the http GET parameter as a command line parameter
that had to start with '/'. MSYS on windows will mangle such paths.

Instead of applying a workaround everywhere (such as an extra '/') we let
get-with-headers.py add the mandatory '/'. That is consistent with the
url path handling in the Mercurial url class.

A few tests sent 'GET ?cmd=...' which is invalid. They will now send 'GET
/?cmd=...'.

This will not enable any tests for being run on windows - only remove one
reason they were disabled.
2012-06-21 03:05:02 +02:00
Mads Kiilerich
490f13d607 tests: hghave outer-repo should be true even if a bad repo is found
Only the abort message 'no repository found' is a reliable indication that
there is no outer repo.
2012-06-20 23:41:21 +02:00
Mads Kiilerich
ccfffc07ba tests: add missing no-outer-repo requirements
Outer repos (if any) will now never be touched by the tests. But it is better
to run without any repos around the tmp directory.
2012-06-20 23:41:21 +02:00
Mads Kiilerich
db42f91a88 tests: convert some 'hghave no-outer-repo' to #if
In some places we instead use 'hg init' to create a well-known outer repo
without any special extensions or other config settings.
2012-06-20 23:41:21 +02:00
Matt Mackall
b95feae305 merge with stable 2012-06-20 12:30:16 -05:00
Matt Mackall
84f289778a merge with i18n 2012-06-20 12:29:08 -05:00
Thomas Arendsen Hein
1dffad0c67 tests: remove execute permission from two unified test files 2012-06-20 17:04:30 +02:00
Thomas Arendsen Hein
ad3dbec4ae graft: allow -r to specify revisions 2012-06-20 17:02:43 +02:00
Thomas Arendsen Hein
0e93bb1709 consistency: use REV instead of REVISION 2012-06-20 16:49:04 +02:00
Thomas Arendsen Hein
64a2699762 export: add optional -r to synopsis
It is not already covered by [OPTION]..., because in this case REV... would
need to be marked optional.
2012-06-20 16:46:10 +02:00
Thomas Arendsen Hein
a0b2b2d9c7 strip: add optional -r to synopsis 2012-06-20 16:44:21 +02:00
Thomas Arendsen Hein
833af3cb43 qimport: use [FILE]... because if -r is used no file is needed 2012-06-20 16:43:09 +02:00
Thomas Arendsen Hein
9e0f26649a mq: abort if no files or revisions are specified for qimport 2012-06-20 16:22:58 +02:00
Mads Kiilerich
f7215835a1 tests: convert some hghave unix-permissions to #if 2012-06-19 01:43:41 +02:00
Mads Kiilerich
8c68acd70f tests: run test-walk.t on windows
A couple of detours and changed paths are used to work around msys path conversion.
2012-06-19 00:20:38 +02:00
Mads Kiilerich
bacb1ab49d tests: better testing of 'glob:glob' in test-walk.t 2012-06-18 23:44:11 +02:00