Using github's linguist to better detect filetypes and to do syntax highlighting.
This commit is contained in:
parent
9ee345750c
commit
5b6019f357
6 changed files with 21 additions and 56 deletions
|
@ -11,10 +11,10 @@
|
|||
- if file.text?
|
||||
.view_file_content
|
||||
- unless file.empty?
|
||||
%div{:class => current_user.dark_scheme ? "black" : "white"}
|
||||
= preserve do
|
||||
= raw file.colorize
|
||||
- else
|
||||
%div{:class => current_user.dark_scheme ? "black" : "white"}
|
||||
= preserve do
|
||||
= raw file.colorize(options: { linenos: 'True'})
|
||||
- else
|
||||
%h3
|
||||
%center Empty file
|
||||
- elsif file.image?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue