diff options
| author | Miklos Vajna <vmiklos@frugalware.org> | 2010-06-27 19:02:07 +0200 |
|---|---|---|
| committer | Miklos Vajna <vmiklos@frugalware.org> | 2010-06-27 19:02:07 +0200 |
| commit | 7353ef90b0682750768b624f7dd6e870bdb75a65 (patch) | |
| tree | 2da8ae6e210d69e710974eaf05597cdb49303d12 | |
| parent | fe5a16c9bd34b61822a0d86253c22c2184bc6f42 (diff) | |
| download | python-fastimport-git-7353ef90b0682750768b624f7dd6e870bdb75a65.tar.gz | |
darcs-fast-import: always invoke darcs add using --boring
| -rwxr-xr-x | exporters/darcs/darcs-fast-import | 7 | ||||
| -rw-r--r-- | exporters/darcs/t/lib.sh | 4 |
2 files changed, 9 insertions, 2 deletions
diff --git a/exporters/darcs/darcs-fast-import b/exporters/darcs/darcs-fast-import index 0c658eb..d190204 100755 --- a/exporters/darcs/darcs-fast-import +++ b/exporters/darcs/darcs-fast-import @@ -108,6 +108,9 @@ class Handler: if os.system("darcs %s" % cmdline) != 0: self.bug("darcs failed") + def invoke_add(self, path): + self.invoke_darcs("add --boring %s" % path) + def handle_mark(self): if self.line.startswith("mark :"): self.mark_num = int(self.line[6:-1]) @@ -199,7 +202,7 @@ class Handler: elif self.line.startswith("C "): src, dest = self.line[:-1].split(' ')[1:] shutil.copy(src.strip('"'), dest.strip('"')) - self.invoke_darcs("add %s" % dest) + self.invoke_add(dest) elif self.line.startswith("M "): items = self.line.split(' ') if items[1] == "120000": @@ -230,7 +233,7 @@ class Handler: break for i in adds: - self.invoke_darcs("add %s" % i) + self.invoke_add(i) sock = subprocess.Popen(["darcs", "record", "--ignore-times", "-a", "--pipe"], stdin=subprocess.PIPE, stdout=subprocess.PIPE) buf = [self.date, self.ident, self.short, self.long] sock.stdin.write("\n".join(buf)) diff --git a/exporters/darcs/t/lib.sh b/exporters/darcs/t/lib.sh index 87c4db9..ee3ec3c 100644 --- a/exporters/darcs/t/lib.sh +++ b/exporters/darcs/t/lib.sh @@ -229,6 +229,10 @@ third line" | git commit -a -F - echo f > file git add file git commit -a -m "file: other -> f" + # this is a boring file for Darcs + touch foo.pyc + git add foo.pyc + git commit -a -m "boring file" cd .. } |
