Show More
@@ -151,7 +151,7 b' class ChangesetController(BaseController' | |||||
151 | for node in c.changeset.added: |
|
151 | for node in c.changeset.added: | |
152 | filenode_old = FileNode(node.path, '') |
|
152 | filenode_old = FileNode(node.path, '') | |
153 | if filenode_old.is_binary or node.is_binary: |
|
153 | if filenode_old.is_binary or node.is_binary: | |
154 | diff = _('binary file') |
|
154 | diff = _('binary file') +'\n' | |
155 | else: |
|
155 | else: | |
156 | f_udiff = differ.get_udiff(filenode_old, node) |
|
156 | f_udiff = differ.get_udiff(filenode_old, node) | |
157 | diff = differ.DiffProcessor(f_udiff).raw_diff() |
|
157 | diff = differ.DiffProcessor(f_udiff).raw_diff() | |
@@ -173,8 +173,10 b' class ChangesetController(BaseController' | |||||
173 | c.changes.append(('changed', node, diff, cs1, cs2)) |
|
173 | c.changes.append(('changed', node, diff, cs1, cs2)) | |
174 |
|
174 | |||
175 | response.content_type = 'text/plain' |
|
175 | response.content_type = 'text/plain' | |
|
176 | ||||
176 | if method == 'download': |
|
177 | if method == 'download': | |
177 | response.content_disposition = 'attachment; filename=%s.patch' % revision |
|
178 | response.content_disposition = 'attachment; filename=%s.patch' % revision | |
|
179 | ||||
178 | parent = True if len(c.changeset.parents) > 0 else False |
|
180 | parent = True if len(c.changeset.parents) > 0 else False | |
179 | c.parent_tmpl = 'Parent %s' % c.changeset.parents[0].raw_id if parent else '' |
|
181 | c.parent_tmpl = 'Parent %s' % c.changeset.parents[0].raw_id if parent else '' | |
180 |
|
182 |
General Comments 0
You need to be logged in to leave comments.
Login now