##// END OF EJS Templates
Merge with crew-stable
Patrick Mezard -
r5247:20770c5d merge default
parent child Browse files
Show More
@@ -1,6 +1,7 b''
1 # git support for the convert extension
1 # git support for the convert extension
2
2
3 import os
3 import os
4 from mercurial import util
4
5
5 from common import NoRepo, commit, converter_source
6 from common import NoRepo, commit, converter_source
6
7
@@ -41,7 +42,8 b' class convert_git(converter_source):'
41
42
42 def catfile(self, rev, type):
43 def catfile(self, rev, type):
43 if rev == "0" * 40: raise IOError()
44 if rev == "0" * 40: raise IOError()
44 fh = self.gitcmd("git-cat-file %s %s 2>/dev/null" % (type, rev))
45 fh = self.gitcmd("git-cat-file %s %s 2>%s" % (type, rev,
46 util.nulldev))
45 return fh.read()
47 return fh.read()
46
48
47 def getfile(self, name, rev):
49 def getfile(self, name, rev):
@@ -101,7 +103,8 b' class convert_git(converter_source):'
101
103
102 def gettags(self):
104 def gettags(self):
103 tags = {}
105 tags = {}
104 fh = self.gitcmd('git-ls-remote --tags "%s" 2>/dev/null' % self.path)
106 fh = self.gitcmd('git-ls-remote --tags "%s" 2>%s' % (self.path,
107 util.nulldev))
105 prefix = 'refs/tags/'
108 prefix = 'refs/tags/'
106 for line in fh:
109 for line in fh:
107 line = line.strip()
110 line = line.strip()
General Comments 0
You need to be logged in to leave comments. Login now