Commit Graph

10 Commits

Author SHA1 Message Date
Matt Mackall
1b05a52143 win32text: drop disabling portion of test
disabling extension leaves dirstate confused about whether affected
files are clean or not, not much point testing it.
2009-06-09 11:55:32 -05:00
Matt Mackall
e7ff3ff5bc merge: allow merging going backwards
New behavior is generally superior and more correct, except possibly
with regards to missing files. hg up . is now effectively a no-op,
which is probably the desired behavior for people expecting to move to
tip, but may surprise people who were expecting deleted files to
reappear.

case 1: update to .

a-w -> a-w

classic: ancestor a
 missing     recreated     right?
 rmed        recreated     WRONG
 added       forgotten     WRONG
 changed     preserved     RIGHT
 conflicted  can't happen

backward merge: ancestor a  (NO EFFECT)
 missing     missing      wrong?
 rm'ed       rm'ed        RIGHT
 added       preserved	  RIGHT
 changed     preserved    RIGHT
 conflicted  can't happen

case 2: update to ancestor of .

a-b-w -> b-w
          \
           a

classic:  ancestor a
 missing       recreated        right?
 rmed          recreated        wrong?
 added         forgotten        wrong?
 changed       preserved        RIGHT
 conflicted    preserved        wrong?

backwards merge: ancestor b
 missing       missing or conflict  right?
 rm'ed         missing or conflict  right?
 changed       preserved            RIGHT
 conflicted    merge                RIGHT
 added         preserved            right?
2009-06-08 18:14:44 -05:00
Martin Geisler
65537ad291 tests: removed redundant "-d '0 0'" from test scripts
The tests are executed with a .hgrc file which adds "-d '0 0'" by
default.
2009-04-26 14:29:02 +02:00
Bryan O'Sullivan
39f59a8aee win32text: be more careful about rejecting violating changesets
We now try to walk changesets in reverse order from newest to oldest,
so that if we see a file multiple times, we treat the newest version
as canonical.

This should prevent us from rejecting a changegroup that contains an
unacceptable commit followed later by a commit that fixes the problem.
2009-04-24 00:06:01 -07:00
Mads Kiilerich
156ce431aa Make it possible to disable filtering for a pattern.
Rationale: Apparently there were no way to disable for example win32text extension locally.

RFC: Can it already be done another way?
2008-10-14 21:28:49 +02:00
Alexis S. L. Carvalho
f5a37c37de revert: update state of files in the "checkout" list
This can make a difference when there are filters involved and

    decode(encode(working-dir-data)) != working-dir-data

even though

    encode(decode(repo-data)) == repo-data

An example is a working dir file that uses only \n when you're using
the win32text extension.
2008-03-18 04:07:39 -03:00
Thomas Arendsen Hein
deb94bc7fe Removed trailing spaces from everything except test output 2008-03-07 00:24:36 +01:00
Jesse Glick
dc05781c40 Provide better context for custom Python encode/decode filters.
While some can function with just some text and an optional command name,
others may want a repository object, a ui object, and a file path.
Use the enhanced information to good effect in win32text.dumbdecode's warning.
2007-12-21 23:21:17 -05:00
Patrick Mezard
d1b62d9bf5 test-win32text: avoid unix2dos, printf extensions 2007-12-21 00:13:00 +01:00
Jesse Glick
e75d3a3d78 Issue 882: add standard hook to reject text files with CRLF.
While the win32text extension does LF <-> CRLF conversion, and will issue a
warning in case a file already in the repository uses CRLF, it provides no
mechanism for verifying that incoming changes use LF. In a large development
team with some Windows users, it is virtually guaranteed that someone will
forget to set up the encode filter correctly and accidentally check in a file
using CRLF, which can cause warnings for other Windows users when they next
fetch changes. Since this is a general problem it is desirable to have a
pre-commit (or -push) hook available to reject such accidents earlier rather
than trying to fix them up after the fact.
2007-12-19 17:02:31 -05:00