Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
remote-bzr: delay blob fetching until the very end
author
Felipe Contreras
<felipe.contreras@gmail.com>
Wed, 1 May 2013 01:09:54 +0000
(20:09 -0500)
committer
Junio C Hamano
<gitster@pobox.com>
Wed, 1 May 2013 05:06:46 +0000
(22:06 -0700)
Might be more efficient, but the real reason to use the marks will be
revealed in upcoming patches.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/remote-helpers/git-remote-bzr
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
c80f4c7
)
diff --git
a/contrib/remote-helpers/git-remote-bzr
b/contrib/remote-helpers/git-remote-bzr
index 7452a572c1f50a37e52364838a761d0b4e4ae371..91b5cda7671f6a4169ce8ec02de987242ef5f9f5 100755
(executable)
--- a/
contrib/remote-helpers/git-remote-bzr
+++ b/
contrib/remote-helpers/git-remote-bzr
@@
-506,10
+506,12
@@
class CustomTree():
return changes
def get_file_with_stat(self, file_id, path=None):
return changes
def get_file_with_stat(self, file_id, path=None):
- return (StringIO.StringIO(self.updates[file_id]['data']), None)
+ mark = self.updates[file_id]['mark']
+ return (StringIO.StringIO(blob_marks[mark]), None)
def get_symlink_target(self, file_id):
def get_symlink_target(self, file_id):
- return self.updates[file_id]['data']
+ mark = self.updates[file_id]['mark']
+ return blob_marks[mark]
def c_style_unescape(string):
if string[0] == string[-1] == '"':
def c_style_unescape(string):
if string[0] == string[-1] == '"':
@@
-553,7
+555,7
@@
def parse_commit(parser):
if parser.check('M'):
t, m, mark_ref, path = line.split(' ', 3)
mark = int(mark_ref[1:])
if parser.check('M'):
t, m, mark_ref, path = line.split(' ', 3)
mark = int(mark_ref[1:])
- f = { 'mode' : m, '
data' : blob_marks[mark]
}
+ f = { 'mode' : m, '
mark' : mark
}
elif parser.check('D'):
t, path = line.split(' ')
f = { 'deleted' : True }
elif parser.check('D'):
t, path = line.split(' ')
f = { 'deleted' : True }