##// END OF EJS Templates
test-eol-*: remove unused config settings
Martin Geisler -
r13521:c1629963 default
parent child Browse files
Show More
@@ -1,77 +1,74
1 1 Testing cloning with the EOL extension
2 2
3 3 $ cat >> $HGRCPATH <<EOF
4 > [diff]
5 > git = True
6 >
7 4 > [extensions]
8 5 > eol =
9 6 >
10 7 > [eol]
11 8 > native = CRLF
12 9 > EOF
13 10
14 11 setup repository
15 12
16 13 $ hg init repo
17 14 $ cd repo
18 15 $ cat > .hgeol <<EOF
19 16 > [patterns]
20 17 > **.txt = native
21 18 > EOF
22 19 $ printf "first\r\nsecond\r\nthird\r\n" > a.txt
23 20 $ hg commit --addremove -m 'checkin'
24 21 adding .hgeol
25 22 adding a.txt
26 23
27 24 Clone
28 25
29 26 $ cd ..
30 27 $ hg clone repo repo-2
31 28 updating to branch default
32 29 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
33 30 $ cd repo-2
34 31 $ cat a.txt
35 32 first\r (esc)
36 33 second\r (esc)
37 34 third\r (esc)
38 35 $ hg cat a.txt
39 36 first
40 37 second
41 38 third
42 39 $ hg remove .hgeol
43 40 $ hg commit -m 'remove eol'
44 41 $ hg push --quiet
45 42 $ cd ..
46 43
47 44 Test clone of repo with .hgeol in working dir, but no .hgeol in tip
48 45
49 46 $ hg clone repo repo-3
50 47 updating to branch default
51 48 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
52 49 $ cd repo-3
53 50
54 51 $ cat a.txt
55 52 first
56 53 second
57 54 third
58 55
59 56 Test clone of revision with .hgeol
60 57
61 58 $ cd ..
62 59 $ hg clone -r 0 repo repo-4
63 60 adding changesets
64 61 adding manifests
65 62 adding file changes
66 63 added 1 changesets with 2 changes to 2 files
67 64 updating to branch default
68 65 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
69 66 $ cd repo-4
70 67 $ cat .hgeol
71 68 [patterns]
72 69 **.txt = native
73 70
74 71 $ cat a.txt
75 72 first\r (esc)
76 73 second\r (esc)
77 74 third\r (esc)
@@ -1,90 +1,86
1 1 Test the EOL hook
2 2
3 $ cat >> $HGRCPATH <<EOF
4 > [diff]
5 > git = True
6 > EOF
7 3 $ hg init main
8 4 $ cat > main/.hg/hgrc <<EOF
9 5 > [extensions]
10 6 > eol =
11 7 >
12 8 > [hooks]
13 9 > pretxnchangegroup = python:hgext.eol.hook
14 10 > EOF
15 11 $ hg clone main fork
16 12 updating to branch default
17 13 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
18 14 $ cd fork
19 15
20 16 Create repo
21 17 $ cat > .hgeol <<EOF
22 18 > [patterns]
23 19 > mixed.txt = BIN
24 20 > crlf.txt = CRLF
25 21 > **.txt = native
26 22 > EOF
27 23 $ hg add .hgeol
28 24 $ hg commit -m 'Commit .hgeol'
29 25
30 26 $ printf "first\nsecond\nthird\n" > a.txt
31 27 $ hg add a.txt
32 28 $ hg commit -m 'LF a.txt'
33 29 $ hg push ../main
34 30 pushing to ../main
35 31 searching for changes
36 32 adding changesets
37 33 adding manifests
38 34 adding file changes
39 35 added 2 changesets with 2 changes to 2 files
40 36
41 37 $ printf "first\r\nsecond\r\nthird\n" > a.txt
42 38 $ hg commit -m 'CRLF a.txt'
43 39 $ hg push ../main
44 40 pushing to ../main
45 41 searching for changes
46 42 adding changesets
47 43 adding manifests
48 44 adding file changes
49 45 added 1 changesets with 1 changes to 1 files
50 46 error: pretxnchangegroup hook failed: a.txt should not have CRLF line endings
51 47 transaction abort!
52 48 rollback completed
53 49 abort: a.txt should not have CRLF line endings
54 50 [255]
55 51
56 52 $ printf "first\nsecond\nthird\n" > a.txt
57 53 $ hg commit -m 'LF a.txt (fixed)'
58 54 $ hg push ../main
59 55 pushing to ../main
60 56 searching for changes
61 57 adding changesets
62 58 adding manifests
63 59 adding file changes
64 60 added 2 changesets with 2 changes to 1 files
65 61
66 62 $ printf "first\nsecond\nthird\n" > crlf.txt
67 63 $ hg add crlf.txt
68 64 $ hg commit -m 'LF crlf.txt'
69 65 $ hg push ../main
70 66 pushing to ../main
71 67 searching for changes
72 68 adding changesets
73 69 adding manifests
74 70 adding file changes
75 71 added 1 changesets with 1 changes to 1 files
76 72 error: pretxnchangegroup hook failed: crlf.txt should not have LF line endings
77 73 transaction abort!
78 74 rollback completed
79 75 abort: crlf.txt should not have LF line endings
80 76 [255]
81 77
82 78 $ printf "first\r\nsecond\r\nthird\r\n" > crlf.txt
83 79 $ hg commit -m 'CRLF crlf.txt (fixed)'
84 80 $ hg push ../main
85 81 pushing to ../main
86 82 searching for changes
87 83 adding changesets
88 84 adding manifests
89 85 adding file changes
90 86 added 2 changesets with 2 changes to 1 files
@@ -1,40 +1,37
1 1 http://mercurial.selenic.com/bts/issue2493
2 2
3 3 Testing tagging with the EOL extension
4 4
5 5 $ cat >> $HGRCPATH <<EOF
6 > [diff]
7 > git = True
8 >
9 6 > [extensions]
10 7 > eol =
11 8 >
12 9 > [eol]
13 10 > native = CRLF
14 11 > EOF
15 12
16 13 setup repository
17 14
18 15 $ hg init repo
19 16 $ cd repo
20 17 $ cat > .hgeol <<EOF
21 18 > [patterns]
22 19 > ** = native
23 20 > EOF
24 21 $ printf "first\r\nsecond\r\nthird\r\n" > a.txt
25 22 $ hg commit --addremove -m 'checkin'
26 23 adding .hgeol
27 24 adding a.txt
28 25
29 26 Tag:
30 27
31 28 $ hg tag 1.0
32 29
33 30 Rewrite .hgtags file as it would look on a new checkout:
34 31
35 32 $ hg update -q null
36 33 $ hg update -q
37 34
38 35 Touch .hgtags file again:
39 36
40 37 $ hg tag 2.0
General Comments 0
You need to be logged in to leave comments. Login now