Commit Graph

15737 Commits

Author SHA1 Message Date
David M. Carr
6878ff4146 subrepo: improve help for git subrepo support
Add details on which commands are supported for git subrepos.
2011-11-03 23:12:30 -04:00
David M. Carr
4025aa1003 subrepo: update help for commit to reflect new default behavior
Update the subrepo help to be consistent with the new default behavior,
which is to abort if any subrepo is dirty.
2011-11-03 23:11:40 -04:00
Hao Lian
e92210d64e largefiles: ensure destination directory exists before findfile links to there
When (1) findfile links a largefile from the user cache to the store
and (2) the store directory doesn't exist yet, findfile errors out. A
simple call to util.makedirs fixes it.
2011-11-03 10:59:32 -04:00
Matt Mackall
864ce9da04 misc: adding missing file close() calls
Spotted by Victor Stinner <victor.stinner@haypocalc.com>
2011-11-03 11:24:55 -05:00
Wagner Bruna
ad3e245fdf i18n: disable translations with conflicting prompt keys (issue3082)
This is just a stopgap until a proper solution is implemented.
2011-11-03 10:52:58 -02:00
Matt Mackall
bd626658e2 Added signature for changeset fa55f5d988cf 2011-11-01 15:37:00 -05:00
Matt Mackall
e576cf8a52 dirstate: don't fail when dropping a not-tracked file (issue3080)
Complex merges with divergent renames can cause a file to be 'moved'
twice, causing dirstate.drop() to be called twice. Rather than try to
ensure there are no unexpected corner cases where this can happen, we
simply ignore drops of files that aren't tracked.
2011-11-01 15:19:37 -05:00
Brodie Rao
114ca03d36 tests: fix readline escape characters in heredoctest.py/test-url.py
This fix mirrors the changes made to test-doctest.py in 04cfbbc5ae97
and 39599b7929c4.

Without this change, tests running heredoctest.py can fail on certain
versions of OS X when TERM is set to xterm-256color:

   $ /opt/local/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python -m heredoctest <<EOF
   > >>> open('b', 'w').write('this' * 1000)
   > EOF
+  \x1b[?1034h (no-eol) (esc)

A similar problem occurs with test-url.py:

  $ ./run-tests.py test-url.py

  --- .../tests/test-url.py.out
  +++ .../tests/test-url.py.err
  @@ -0,0 +1 @@
  +
  ERROR: .../test-url.py output changed
  !
  Failed test-url.py: output changed
  # Ran 1 tests, 0 skipped, 1 failed.
2011-11-01 12:25:54 -07:00
Matt Mackall
b2142fe17e merge with i18n 2011-11-01 12:49:06 -05:00
Wagner Bruna
c89e84c137 i18n-pt_BR: synchronized with 8e74a4eb8500 2011-10-31 11:27:16 -02:00
Wagner Bruna
91c19f6dbb merge with i18n 2011-10-31 11:24:37 -02:00
FUJIWARA Katsunori
f6b7a91d98 minirst: use unicode string as intermediate form for replacement
# this change redones part of e0051068893a, backed out by 38c00c035629

Some character encodings use ASCII characters other than
control/alphabet/digit as a part of multi-bytes characters, so direct
replacing with such characters on strings in local encoding causes
invalid byte sequences.

[mpm: test changed to simple doctest]
2011-10-31 21:06:18 +09:00
Matt Mackall
9580de9b45 util: add a doctest for empty sha() calls 2011-10-31 15:41:39 -05:00
FUJIWARA Katsunori
232b6880eb i18n-ja: synchronized with 4576ace762a0 2011-10-31 20:58:49 +09:00
Matt Mackall
2988d59e97 keyword: backout realpath change (issue3071) 2011-10-30 12:10:11 -05:00
Matt Mackall
7215130ac4 strip: backout 9aac86f54486 (issue3077) 2011-10-30 12:10:09 -05:00
Matt Mackall
2f72e8b497 largefiles: avoid checking requirements on every command
When largefiles is enabled, commands on large repositories which don't
require largefiles could be slowed down substantially. Disable
checking this for every command.
2011-10-29 17:38:13 -05:00
Na'Tosha Bard
5e8efa0656 largefiles: shorten test suite by using log --template 2011-10-28 18:50:54 +02:00
Na'Tosha Bard
0e6729399b largefiles: fix bad bug where transplanting a changeset with a largefile will result in an old largefile being comitted later on 2011-10-28 18:48:24 +02:00
Na'Tosha Bard
f4916e10c1 largefiles: test that a largefile cannot accidentally be re-added as a regular file 2011-10-28 18:17:44 +02:00
Matt Mackall
b066b57e3c backout 17bc9a6bb165 (issue3077) (issue3071)
Using util.realpath turns out to create complex issues on both Mac and
Windows. Back this change out for the release.
2011-10-29 11:02:23 -05:00
Martin Geisler
af63514154 largefiles: fix uppercase in abort message 2011-10-28 15:00:21 +02:00
Thomas Arendsen Hein
467f4af92f Makefile: adjust example, test-merge1 is now test-merge1.t 2011-10-28 12:59:50 +02:00
Thomas Arendsen Hein
2e23955210 tests: use $DAEMON_PIDS and killdaemons in largefiles test
$DAEMON_PIDS is used by tests to make sure there will be no leftover
processes, the cycling through ports is needed because they are not
available for a new bind that quickly on some systems.

There are not enough $HGPORT variables available for each hg serve,
so use the killdaemons script before reusing ports.
2011-10-28 12:44:19 +02:00
Thomas Arendsen Hein
c566f581fc tests: make largefiles test use $HGPORT instead of 8001 2011-10-28 11:16:39 +02:00
Matt Mackall
4240c7a313 merge in another fix on the wrong branch 2011-10-27 18:35:07 -05:00
Brodie Rao
aabbd72d18 hgweb: fix dynamic date calculation not working under Safari
While Chrome, Firefox, and IE 6+ support the current date format being
passed to Date(), Safari doesn't:

> new Date('Mon Oct 24 13:58:01 2011 +0200')
  Invalid Date

However, the rfc822date format--officially supported by
ECMAScript[1]--does work:

> new Date('Mon, 24 Oct 2011 13:58:01 +0200')
  Mon Oct 24 2011 04:58:01 GMT-0700 (PDT)

This change replaces all instances of {date|date} in HTML with
{date|rfc822date}. For elements that only have the "age" class,
there's no outward change for users with JavaScript enabled. For
elements with both the "age" and "date" classes, the full date
displayed uses the new format.

Tested in IE 6, Safari 5.1.1, Google Chrome 15, and Firefox 7.0.1.

[1]: https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Date/parse
2011-10-27 11:57:08 -07:00
Matt Mackall
f13ffccaf7 tests: fix spurious largefiles test failure on Cygwin 2011-10-27 18:15:34 -05:00
Stefano Tortarolo
9b3ae256e5 i18n-it: fixed wrong message 2011-10-26 22:35:15 +02:00
Matt Mackall
36e0650c7d setup: set env global earlier (3073) 2011-10-26 12:56:27 -05:00
Peer Stritzinger
ed0c1f398e revert: fix missing removes when parent was changed in dirstate
When dirstate parent is changed with dirstate.setparent before a
revert so it no longer points to where the dirstate refered to, revert
does not remove all files it should:

Revert to a different revision needs also to remove files that are not
found through disptables and not in the context or parent manifest.
2011-10-26 18:47:12 +02:00
Matt Mackall
8971e5af3c check-code: fix issues with finding patterns in unified tests, fix tests
- old-style patterns without ^ were getting improperly anchored
- finditer was matching against beginning of line poorly
- \s was matching newlines
- [^x] was matching newlines

so we:

- remove earlier hacks for multiline matching
- fix unified test anchoring by adding .*
- replace \s with [ \t]
- replace [^x] with [^\nx]
- force all matches into multiline mode so ^ anchors work

This uncovers a number of test issues that are then repaired.
2011-10-27 17:22:04 -05:00
Pierre-Yves David
01ab70718a phases: update exchange test to include node hash.
This will be easier for exchange test.
2011-10-26 14:30:43 +02:00
Pierre-Yves David
ca1e55e405 phases: add a phases.publish option
What is a "publishing repository"?
==================================

Setting a repository as "publishing" alter its behavior **when used as a
server**: all changesets are **seen** as public changesets by clients.

So, pushing to a "publishing" repository is the most common way to make
changesets public: pushed changesets are seen as public on the remote side and
marked as such on local side.

Note: the "publishing" property have no effects for local operations.

Old repository are publishing
=============================

Phase is the first step of a series of features aiming at handling mutable
history within mercurial. Old client do not support such feature and are unable
to hold phase data. The safest solution is to consider as public any changeset
going through an old client.

Moreover, most hosting solution will not support phase from the beginning.
Having old clients seen as public repositories will not change their usage:
public repositories where you push *immutable* public changesets *shared* with
others.

Why is "publishing" the default?
================================

We discussed above that any changeset from a non-phase aware repository should
be seen as public.  This means that in the following scenario, X is pulled as
public::

  ~/A$ old-hg init
  ~/A$ echo 'babar' > jungle
  ~/A$ old-hg commit -mA 'X'
  ~/A$ cd ../B
  ~/B$ new-hg pull ../A # let's pretend A is served by old-hg
  ~/B$ new-hg log -r tip
     summary:     X
     phase:       public

We want to keep this behavior while creating/serving the A repository with
``new-hg``. Although committing with any ``new-hg`` creates a draft changeset.
To stay backward compatible, the pull must see the new commit as public.
Non-publishing server will advertise them as draft. Having publishing repository
the default is thus necessary to ensure this backward compatibility.

This default value can also be expressed with the following sentence: "By
default, without any configuration, everything you exchange with the outside is
immutable.". This behaviour seems sane.

Why allow draft changeset in publishing repository
=====================================================

Note: The publish option is aimed at controlling the behavior of *server*.
Changeset in any state on a publishing server will **always*** be seen as public
by other client. "Passive" repository which are only used as server for pull and
push operation are not "affected" by this section.

As in the choice for default, the main reason to allow draft changeset in
publishing server is backward compatibility. With an old client, the following
scenario is valid::

  ~/A$ old-hg init
  ~/A$ echo 'babar' > jungle
  ~/A$ old-hg commit -mA 'X'
  ~/A$ old-hg qimport -r . # or any other mutable operation on X

If the default is publishing and new commits in such repository are "public" The
following operation will be denied as X will be an **immutable** public
changeset. However as other clients see X as public, any pull//push (or event
pull//pull) will mark X as public in repo A.

Allowing enforcement of public changeset only repository through config is
probably something to do. This could be done with another "strict" option or a
third value config for phase related option (mode=public, publishing(default),
mutable)
2011-12-15 11:57:33 +01:00
Augie Fackler
551016898f zsh completion: add support for qfinish 2011-12-12 11:54:22 -06:00
Matt Mackall
31beaa1cd1 merge with crew 2011-12-15 14:24:38 -06:00
Matt Mackall
6f6f3c4a5f merge with i18n 2011-12-15 14:24:29 -06:00
Martin Geisler
d6b9b24fa1 merge with stable 2011-12-15 16:26:33 +01:00
Fabian Kreutz
6c2afb2d63 i18n-de: Error reported by Mathias Goldau and commit msg shortened 2011-12-10 20:48:33 +02:00
Fabian Kreutz
35b908ab59 i18n-de: mostly update fuzzies
More helptexts have been changed into on id per paragraph. New keywords
added. hg example calls changed to :hg:`..` syntax (where changed in EN).
2011-12-10 20:22:33 +02:00
Martin Geisler
237daccf1b dispatch: remove extra newline
The return statement belongs to the lines above.
2011-12-10 18:40:05 +01:00
Martin Geisler
f89c093d08 merge with stable 2011-12-09 17:58:12 +01:00
Martin Geisler
1fbdd9520a largefiles: use lfutil functions
Using regular expressions to cut off a (fixed) string prefix is overly
complicated and wasteful.
2011-12-09 17:34:57 +01:00
Martin Geisler
313aade451 largefiles: fix indentation 2011-12-09 17:34:56 +01:00
Ion Savin
b96d2a90cd annotate: show full changeset hash when invoked with --debug and -c 2011-12-09 14:14:30 +02:00
Alexander Sauta
c22bc9b9e6 i18n-ru: eol, fetch, color, LargeFiles, gpg, keywords translated 2011-12-08 00:05:24 +03:00
Martin Geisler
9b8776da45 largefiles: remove pre-1.7 compatibility code
Mercurial 1.7 added the --subrepos flag to status and archive and the
largefiles code was still compatible with the old method signatures.
2011-12-07 16:25:51 +01:00
Martin Geisler
ae8ca6aff5 merge: make debug output easier to read
I always found it hard to figure out what the debug code meant without
the separators.
2011-12-09 17:34:53 +01:00
Thomas Arendsen Hein
8337fb5549 sshrepo: add more safe characters (issue2983)
Extended the list of safe characters introduced in c3194121de6c to include
everything from pipes._safechars, which is only available on Unix platforms.
Place "-" at the end of the range to avoid backslash-escape.
New characters: @%+=:,
2011-12-09 15:50:33 +01:00
Matt Mackall
a968007692 merge with stable 2011-12-08 16:01:44 -06:00