Beispiel #1
0
 def make_template_context(self, *args):
     super(BlameView, self).make_template_context(*args)
     if self.context['can_render']:
         line_commits = self.context['repo'].blame(self.context['commit'], self.context['path'])
         replace_dupes(line_commits, None)
         self.context.update({
             'rendered_code': self.render_code(render_markup=False),
             'line_commits': line_commits,
         })
Beispiel #2
0
 def make_template_context(self, *args):
     super(BlameView, self).make_template_context(*args)
     if self.context['can_render']:
         line_commits = self.context['repo'].blame(self.context['commit'],
                                                   self.context['path'])
         replace_dupes(line_commits, None)
         self.context.update({
             'rendered_code':
             self.render_code(render_markup=False),
             'line_commits':
             line_commits,
         })
Beispiel #3
0
 def make_template_context(self, *args):
     super(BlameView, self).make_template_context(*args)
     if self.context["can_render"]:
         line_commits = self.context["repo"].blame(self.context["commit"],
                                                   self.context["path"])
         replace_dupes(line_commits, None)
         self.context.update({
             "rendered_code":
             self.render_code(render_markup=False),
             "line_commits":
             line_commits,
         })
Beispiel #4
0
 def make_template_context(self, *args):
     super(BlameView, self).make_template_context(*args)
     if self.context['can_render']:
         rendered_code = pygmentize(
             force_unicode(self.context['blob_or_tree'].data),
             self.context['filename'],
             render_markup=False,
         )
         line_commits = self.context['repo'].blame(self.context['commit'], self.context['path'])
         replace_dupes(line_commits, None)
         self.context.update({
             'rendered_code': rendered_code,
             'line_commits': line_commits,
         })
Beispiel #5
0
 def make_template_context(self, *args):
     super(BlameView, self).make_template_context(*args)
     if self.context["can_render"]:
         line_commits = self.context["repo"].blame(self.context["commit"], self.context["path"])
         replace_dupes(line_commits, None)
         self.context.update({"rendered_code": self.render_code(render_markup=False), "line_commits": line_commits})