##// END OF EJS Templates
largefiles: fix confusion upon removal of added largefile (issue3176)...
Na'Tosha Bard -
r15786:aca0f2b3 stable
parent child Browse files
Show More
@@ -130,7 +130,7 b' def override_remove(orig, ui, repo, *pat'
130 orig(ui, repo, *pats, **opts)
130 orig(ui, repo, *pats, **opts)
131 restorematchfn()
131 restorematchfn()
132
132
133 after, force = opts.get('after'), opts.get('force')
133 after = opts.get('after')
134 if not pats and not after:
134 if not pats and not after:
135 raise util.Abort(_('no files specified'))
135 raise util.Abort(_('no files specified'))
136 m = scmutil.match(repo[None], pats, opts)
136 m = scmutil.match(repo[None], pats, opts)
@@ -145,12 +145,10 b' def override_remove(orig, ui, repo, *pat'
145
145
146 def warn(files, reason):
146 def warn(files, reason):
147 for f in files:
147 for f in files:
148 ui.warn(_('not removing %s: %s (use -f to force removal)\n')
148 ui.warn(_('not removing %s: %s (use forget to undo)\n')
149 % (m.rel(f), reason))
149 % (m.rel(f), reason))
150
150
151 if force:
151 if after:
152 remove, forget = modified + deleted + clean, added
153 elif after:
154 remove, forget = deleted, []
152 remove, forget = deleted, []
155 warn(modified + added + clean, _('file still exists'))
153 warn(modified + added + clean, _('file still exists'))
156 else:
154 else:
@@ -50,6 +50,18 b' Remove both largefiles and normal files.'
50 $ hg commit -m "remove files"
50 $ hg commit -m "remove files"
51 $ ls
51 $ ls
52 sub
52 sub
53 $ echo "testlargefile" > large1-test
54 $ hg add --large large1-test
55 $ hg st
56 A large1-test
57 $ hg rm large1-test
58 not removing large1-test: file has been marked for add (use forget to undo)
59 $ hg st
60 A large1-test
61 $ hg forget large1-test
62 $ hg st
63 ? large1-test
64 $ rm large1-test
53
65
54 Copy both largefiles and normal files (testing that status output is correct).
66 Copy both largefiles and normal files (testing that status output is correct).
55
67
General Comments 0
You need to be logged in to leave comments. Login now