Merge remote-tracking branch 'source/master'

This commit is contained in:
DX-MON
2014-09-03 18:09:52 +01:00
44 changed files with 9001 additions and 320 deletions

View File

@@ -1,6 +1,4 @@
require 'linguist/generated'
require 'linguist/language'
require 'charlock_holmes'
require 'escape_utils'
require 'mime/types'

View File

@@ -54,7 +54,7 @@ module Linguist
name == 'Gemfile.lock' ||
minified_files? ||
compiled_coffeescript? ||
xcode_project_file? ||
xcode_file? ||
generated_parser? ||
generated_net_docfile? ||
generated_net_designer_file? ||
@@ -67,14 +67,14 @@ module Linguist
generated_by_zephir?
end
# Internal: Is the blob an XCode project file?
# Internal: Is the blob an Xcode file?
#
# Generated if the file extension is an XCode project
# Generated if the file extension is an Xcode
# file extension.
#
# Returns true of false.
def xcode_project_file?
['.xib', '.nib', '.storyboard', '.pbxproj', '.xcworkspacedata', '.xcuserstate'].include?(extname)
def xcode_file?
['.nib', '.xcworkspacedata', '.xcuserstate'].include?(extname)
end
# Internal: Is the blob minified files?
@@ -235,7 +235,7 @@ module Linguist
#
# Returns true or false.
def composer_lock?
!!name.match(/composer.lock/)
!!name.match(/composer\.lock/)
end
# Internal: Is the blob a generated by Zephir
@@ -256,3 +256,4 @@ module Linguist
end
end
end

View File

@@ -9,6 +9,8 @@ end
require 'linguist/classifier'
require 'linguist/heuristics'
require 'linguist/samples'
require 'linguist/file_blob'
require 'linguist/blob_helper'
module Linguist
# Language names that are recognizable by GitHub. Defined languages
@@ -530,6 +532,7 @@ module Linguist
if extnames = extensions[name]
extnames.each do |extname|
if !options['extensions'].include?(extname)
warn "#{name} has a sample with extension (#{extname}) that isn't explicitly defined in languages.yml" unless extname == '.script!'
options['extensions'] << extname
end
end

View File

@@ -28,6 +28,16 @@ ABAP:
extensions:
- .abap
AGS Script:
type: programming
lexer: C++
color: "#B9D9FF"
aliases:
- ags
extensions:
- .asc
- .ash
ANTLR:
type: programming
color: "#9DC3FF"
@@ -35,6 +45,12 @@ ANTLR:
extensions:
- .g4
APL:
type: programming
color: "#8a0707"
extensions:
- .apl
ASP:
type: programming
color: "#6a40fd"
@@ -321,7 +337,7 @@ CLIPS:
CMake:
extensions:
- .cmake
- .cmake.in
- .in
filenames:
- CMakeLists.txt
@@ -346,6 +362,14 @@ Ceylon:
extensions:
- .ceylon
Chapel:
type: programming
color: "#8dc63f"
aliases:
- chpl
extensions:
- .chpl
ChucK:
lexer: Java
extensions:
@@ -354,9 +378,8 @@ ChucK:
Cirru:
type: programming
color: "#aaaaff"
# ace_mode: cirru
# lexer: Cirru
lexer: Text only
ace_mode: cirru
lexer: Cirru
extensions:
- .cirru
@@ -380,7 +403,7 @@ Clojure:
- .cljscm
- .cljx
- .hic
- .cljs.hl
- .hl
filenames:
- riemann.config
@@ -403,14 +426,27 @@ CoffeeScript:
ColdFusion:
type: programming
group: ColdFusion
lexer: Coldfusion HTML
ace_mode: coldfusion
color: "#ed2cd6"
search_term: cfm
aliases:
- cfm
- cfml
extensions:
- .cfm
ColdFusion CFC:
type: programming
group: ColdFusion
lexer: Coldfusion CFC
ace_mode: coldfusion
color: "#ed2cd6"
search_term: cfc
aliases:
- cfc
extensions:
- .cfc
Common Lisp:
@@ -444,6 +480,7 @@ Coq:
type: programming
extensions:
- .coq
- .v
Cpp-ObjDump:
type: data
@@ -479,6 +516,12 @@ Cuda:
- .cu
- .cuh
Cycript:
type: programming
lexer: JavaScript
extensions:
- .cy
Cython:
type: programming
group: Python
@@ -533,6 +576,7 @@ Dart:
Diff:
extensions:
- .diff
- .patch
Dogescript:
type: programming
@@ -581,7 +625,7 @@ Eagle:
Eiffel:
type: programming
lexer: Text only
lexer: Eiffel
color: "#946d57"
extensions:
- .e
@@ -601,7 +645,7 @@ Elm:
Emacs Lisp:
type: programming
lexer: Scheme
lexer: Common Lisp
color: "#c065db"
aliases:
- elisp
@@ -612,11 +656,20 @@ Emacs Lisp:
- .el
- .emacs
EmberScript:
type: programming
color: "#f64e3e"
lexer: CoffeeScript
extensions:
- .em
- .emberscript
Erlang:
type: programming
color: "#0faf8d"
extensions:
- .erl
- .escript
- .hrl
F#:
@@ -692,6 +745,7 @@ Forth:
extensions:
- .fth
- .4th
- .forth
Frege:
type: programming
@@ -800,6 +854,9 @@ Gosu:
color: "#82937f"
extensions:
- .gs
- .gst
- .gsx
- .vark
Grace:
type: programming
@@ -835,6 +892,7 @@ Groovy:
color: "#e69f56"
extensions:
- .groovy
- .gradle
- .grt
- .gtpl
- .gvy
@@ -857,7 +915,6 @@ HTML:
extensions:
- .html
- .htm
- .html.hl
- .st
- .xhtml
@@ -877,9 +934,7 @@ HTML+ERB:
- erb
extensions:
- .erb
- .erb.deface
- .html.erb
- .html.erb.deface
- .deface
HTML+PHP:
type: markup
@@ -897,17 +952,14 @@ Haml:
type: markup
extensions:
- .haml
- .haml.deface
- .html.haml.deface
- .deface
Handlebars:
type: markup
lexer: Text only
lexer: Handlebars
extensions:
- .handlebars
- .hbs
- .html.handlebars
- .html.hbs
Harbour:
type: programming
@@ -933,7 +985,7 @@ Haxe:
Hy:
type: programming
lexer: Clojure
lexer: Hy
ace_mode: clojure
color: "#7891b1"
extensions:
@@ -945,6 +997,13 @@ IDL:
color: "#e3592c"
extensions:
- .pro
- .dlm
IGOR Pro:
type: programming
lexer: Igor
extensions:
- .ipf
INI:
type: data
@@ -967,7 +1026,7 @@ Idris:
Inform 7:
type: programming
lexer: Text only
lexer: Inform 7
wrap: true
extensions:
- .ni
@@ -1019,6 +1078,7 @@ JSON:
searchable: false
extensions:
- .json
- .lock
- .sublime-keymap
- .sublime-mousemap
- .sublime-project
@@ -1140,6 +1200,12 @@ LFE:
LLVM:
extensions:
- .ll
LabVIEW:
type: programming
lexer: Text only
extensions:
- .lvproj
Lasso:
type: programming
@@ -1147,6 +1213,9 @@ Lasso:
color: "#2584c3"
extensions:
- .lasso
- .las
- .lasso9
- .ldml
Latte:
type: markup
@@ -1225,6 +1294,14 @@ Logtalk:
- .lgt
- .logtalk
LookML:
type: programming
lexer: YAML
ace_mode: yaml
color: "#652B81"
extensions:
- .lookml
Lua:
type: programming
ace_mode: lua
@@ -1232,6 +1309,7 @@ Lua:
extensions:
- .lua
- .nse
- .pd_lua
- .rbxs
interpreters:
- lua
@@ -1297,7 +1375,7 @@ Mathematica:
- .mathematica
- .m
- .nb
lexer: Text only
lexer: Mathematica
Matlab:
type: programming
@@ -1345,7 +1423,7 @@ MiniD: # Legacy
Mirah:
type: programming
lexer: Ruby
search_term: ruby
search_term: mirah
color: "#c7a938"
extensions:
- .druby
@@ -1377,6 +1455,7 @@ Myghty:
NSIS:
extensions:
- .nsi
- .nsh
Nemerle:
type: programming
@@ -1441,6 +1520,7 @@ OCaml:
color: "#3be133"
extensions:
- .ml
- .eliom
- .eliomi
- .ml4
- .mli
@@ -1461,6 +1541,7 @@ Objective-C:
- objc
extensions:
- .m
- .h
Objective-C++:
type: programming
@@ -1492,6 +1573,13 @@ Opa:
extensions:
- .opa
Opal:
type: programming
color: "#f7ede0"
lexer: Text only
extensions:
- .opal
OpenCL:
type: programming
group: C
@@ -1508,6 +1596,13 @@ OpenEdge ABL:
- abl
extensions:
- .p
- .cls
OpenSCAD:
type: programming
lexer: Text only
extensions:
- .scad
Org:
type: prose
@@ -1546,6 +1641,7 @@ PHP:
- .php
- .aw
- .ctp
- .module
- .php3
- .php4
- .php5
@@ -1557,7 +1653,7 @@ PHP:
Pan:
type: programming
lexer: Text only
lexer: Pan
color: '#cc0000'
extensions:
- .pan
@@ -1594,6 +1690,7 @@ Pascal:
extensions:
- .pas
- .dfm
- .dpr
- .lpr
Perl:
@@ -1603,12 +1700,15 @@ Perl:
extensions:
- .pl
- .PL
- .cgi
- .fcgi
- .perl
- .ph
- .plx
- .pm
- .pod
- .psgi
- .t
interpreters:
- perl
@@ -1625,6 +1725,13 @@ Perl6:
- .pl6
- .pm6
PigLatin:
type: programming
color: "#fcd7de"
lexer: Text only
extensions:
- .pig
Pike:
type: programming
color: "#066ab2"
@@ -1777,7 +1884,7 @@ R:
RDoc:
type: prose
lexer: Text only
lexer: Rd
ace_mode: rdoc
wrap: true
extensions:
@@ -1817,6 +1924,7 @@ Racket:
- .rkt
- .rktd
- .rktl
- .scrbl
Ragel in Ruby Host:
type: programming
@@ -1886,7 +1994,10 @@ Ruby:
- .god
- .irbrc
- .mspec
- .pluginspec
- .podspec
- .rabl
- .rake
- .rbuild
- .rbw
- .rbx
@@ -1931,6 +2042,14 @@ SCSS:
extensions:
- .scss
SQF:
type: programming
color: "#FFCB1F"
lexer: C++
extensions:
- .sqf
- .hqf
SQL:
type: data
ace_mode: sql
@@ -1960,6 +2079,7 @@ Sass:
group: CSS
extensions:
- .sass
- .scss
Scala:
type: programming
@@ -1967,6 +2087,7 @@ Scala:
color: "#7dd3b0"
extensions:
- .scala
- .sbt
- .sc
Scaml:
@@ -1982,6 +2103,7 @@ Scheme:
- .scm
- .sld
- .sls
- .sps
- .ss
interpreters:
- guile
@@ -1993,6 +2115,8 @@ Scilab:
type: programming
extensions:
- .sci
- .sce
- .tst
Self:
type: programming
@@ -2012,8 +2136,10 @@ Shell:
- zsh
extensions:
- .sh
- .bash
- .bats
- .tmux
- .zsh
interpreters:
- bash
- sh
@@ -2080,6 +2206,7 @@ Standard ML:
extensions:
- .ML
- .fun
- .sig
- .sml
Stata:
@@ -2160,10 +2287,13 @@ TeX:
extensions:
- .tex
- .aux
- .bbx
- .bib
- .cbx
- .cls
- .dtx
- .ins
- .lbx
- .ltx
- .mkii
- .mkiv
@@ -2280,6 +2410,7 @@ Visual Basic:
extensions:
- .vb
- .bas
- .cls
- .frm
- .frx
- .vba
@@ -2308,6 +2439,7 @@ XML:
- wsdl
extensions:
- .xml
- .ant
- .axml
- .ccxml
- .clixml
@@ -2321,6 +2453,7 @@ XML:
- .fsproj
- .glade
- .grxml
- .ivy
- .jelly
- .kml
- .launch

File diff suppressed because it is too large Load Diff

View File

@@ -36,6 +36,10 @@
# Bootstrap minified css and js
- (^|/)bootstrap([^.]*)(\.min)?\.(js|css)$
# Font Awesome
- font-awesome.min.css
- font-awesome.css
# Foundation css
- foundation.min.css
- foundation.css
@@ -43,8 +47,17 @@
# Normalize.css
- normalize.css
# Bourbon SCSS
- (^|/)[Bb]ourbon/.*\.css$
- (^|/)[Bb]ourbon/.*\.scss$
# Animate.css
- animate.css
- animate.min.css
# Vendored dependencies
- thirdparty/
- third[-_]?party/
- 3rd[-_]?party/
- vendors?/
- extern(al)?/
@@ -112,6 +125,10 @@
- (^|/)modernizr\-\d\.\d+(\.\d+)?(\.min)?\.js$
- (^|/)modernizr\.custom\.\d+\.js$
# Knockout
- (^|/)knockout-(\d+\.){3}(debug\.)?js$
- knockout-min.js
## Python ##
# django
@@ -198,6 +215,9 @@
- (^|/)cordova([^.]*)(\.min)?\.js$
- (^|/)cordova\-\d\.\d(\.\d)?(\.min)?\.js$
# Foundation js
- foundation(\..*)?\.js$
# Vagrant
- ^Vagrantfile$

View File

@@ -1,3 +1,3 @@
module Linguist
VERSION = "3.0.3"
VERSION = "3.1.2"
end