Using github's linguist to better detect filetypes and to do syntax highlighting.

This commit is contained in:
Arthur Schreiber 2012-04-20 23:21:12 +02:00
parent 9ee345750c
commit 5b6019f357
6 changed files with 21 additions and 56 deletions

View file

@ -1,10 +1,7 @@
require 'grit'
require 'pygments'
require "utils"
Grit::Blob.class_eval do
include Utils::FileHelper
include Utils::Colorize
include Linguist::BlobHelper
end
#monkey patch raw_object from string
@ -15,7 +12,7 @@ Grit::GitRuby::Internal::RawObject.class_eval do
end
Grit::Diff.class_eval do
Grit::Diff.class_eval do
def old_path
Gitlabhq::Encode.utf8 a_path
end