Commit Graph

2094 Commits

Author SHA1 Message Date
Garen Torikian 26ab33754f Merge master 2014-11-28 11:04:53 -08:00
Lars Brinkhoff 2d940e72c2 Add F# and GLSL samples. Add Forth and GLSL extension .fs.
Add heuristic to disambiguate between F#, Forth, and GLSL.
2014-11-27 06:56:26 +01:00
Brandon Keepers 689a209ed9 Merge remote-tracking branch 'origin/master' into interpreters-in-samples
* origin/master:
  byebug requires ruby 2.0
  Remove test for removed extension
  Merge branch 'master' into 1233-local
  Removing pry runtime dependency
  Moving to fixtures
  Language detection test for non-sample files
  Refactoring of Language.detect
  Try shebang detection if the extension is unknown
  Change unknown extension of PHP sample file
2014-11-26 16:25:15 -05:00
Arfon Smith 412af86cb8 Merge pull request #1538 from github/1233-local
Detection based on the shebang (updated)
2014-11-26 14:47:12 -06:00
Brandon Keepers 06c0cb916b add rake interpreter 2014-11-26 15:40:40 -05:00
Brandon Keepers b3a49ce627 add python3 interpreter 2014-11-26 15:40:33 -05:00
Brandon Keepers ce31e23006 Merge remote-tracking branch 'origin/master' into interpreters-in-samples
* origin/master: (30 commits)
  Add byebug
  Link to Lightshow in CONTRIBUTING.md
  Switch to a better F# grammar
  Bump Rugged again
  Checkout the master for testing
  Rugged 0.22.0b3
  Reordering
  Bump version to 4.0.3
  Add some docs for tm_scope
  Change NONE to none
  Checking other case for Chart.jS
  Test that all languages have grammars
  Fix RHTML's tm_scope
  Chart JS is vendored
  Switch to a better grammar for Bro
  reorder again…
  put cjsx at the top
  Use a SQF grammar for SQF files
  move cjsx before iced
  move cjsx before iced
  ...

Conflicts:
	lib/linguist/languages.yml
2014-11-26 15:17:08 -05:00
Brandon Keepers 6a4bf3fa65 Merge pull request #1731 from github/multiple-ext-segments
Support for multiple file extension segments
2014-11-26 15:09:15 -05:00
Arfon Smith 208a3ff480 Merge branch 'master' into 1233-local
Conflicts:
	lib/linguist/language.rb
2014-11-25 17:04:43 -06:00
Garen Torikian 4603f3b2e7 Update languages.yml to always include ace_mode 2014-11-24 11:38:51 -08:00
Brandon Keepers 7cbc4bc144 Merge pull request #1751 from roodboi/master
add .cjsx extension for Facebook’s JSX in coffescript
2014-11-24 11:30:04 -05:00
Garen Torikian 897c2c5ab6 Add missing ace_mode values wherever necessary 2014-11-23 21:16:21 -08:00
Arfon Smith b556425037 Reordering 2014-11-21 13:10:45 -06:00
Arfon Smith 6131d17c02 Merge pull request #1748 from mrego/xht-extension
Add support for .xht extension which is used in some XHTML files
2014-11-21 12:48:58 -06:00
Adam Roben 4ce9048f8d Bump version to 4.0.3 2014-11-21 11:56:17 -05:00
Adam Roben 04f1b1df48 Merge pull request #1756 from github/test-for-grammars
Test that all languages have grammars
2014-11-21 11:54:46 -05:00
Adam Roben f9c36345c3 Add some docs for tm_scope 2014-11-21 11:53:52 -05:00
Adam Roben ec3967d080 Change NONE to none
NONE is a little shouty.
2014-11-21 11:52:29 -05:00
Arfon Smith 05a88b5b7e Merge pull request #1754 from github/chart-js
Chart js
2014-11-21 09:30:20 -06:00
Adam Roben 49247e9ec2 Test that all languages have grammars
This will make CI fail if someone adds a new language but neglects to
add a new grammar for it. This should make it easier for people to
review PRs, as CI will help them to make sure a new grammar gets added.

However, we currently support some languages that have no grammars, and
we may support more in the future. So you can explicitly mark the
language as having no grammar by setting `tm_scope: NONE` in
languages.yml.
2014-11-21 09:48:52 -05:00
Adam Roben e702b453ec Fix RHTML's tm_scope
I missed this back in 9595e2ba7e.
2014-11-21 09:29:06 -05:00
Arfon Smith 38190d92fc Chart JS is vendored 2014-11-21 08:24:33 -06:00
Dimitri Kennedy b283548c0f reorder again… 2014-11-20 18:36:08 -05:00
Dimitri Kennedy 2352ce77c9 put cjsx at the top 2014-11-20 17:38:38 -05:00
Adam Roben 2054afc741 Use a SQF grammar for SQF files
This produces better highlighting than using the C++ grammar.

The grammar is licensed under the Apache 2.0 license.
2014-11-20 17:22:55 -05:00
Dimitri Kennedy 9d3b9964b5 move cjsx before iced 2014-11-20 17:08:21 -05:00
Dimitri Kennedy 79c1d21a0f move cjsx before iced 2014-11-20 17:08:10 -05:00
Dimitri Kennedy a17f6c8ae1 add .cjsx extension for Facebook’s JSX in coffescript 2014-11-20 14:56:09 -05:00
Brandon Keepers 9823af0cb4 Fix for shebang with relative bin
`#!/usr/bin/env bin/linguist` is a valid shebang
2014-11-20 12:50:35 -05:00
Brandon Keepers 45384bd498 More missing interpreters 2014-11-20 12:29:16 -05:00
Brandon Keepers 56bfde998b Only strip minor version off of interpreters
This used to turn `python2.4` into `python`, which causes trouble with
`perl6`, which is a different language definition.
2014-11-20 12:28:30 -05:00
Brandon Keepers 870feb8592 Add missing interpreters 2014-11-20 11:27:54 -05:00
Brandon Keepers eccea65641 Fix for interpreters not getting add to samples.json 2014-11-20 11:14:05 -05:00
Florian Kaiser 9658b02502 add Chart.js as vendor
http://www.chartjs.org
2014-11-20 10:02:45 +01:00
Manuel Rego Casasnovas b44e58dd7f Add support for .xht extension which is used in some XHTML files 2014-11-19 23:08:51 +01:00
Adam Roben 011c654c2a Bump version to v4.0.2 2014-11-19 12:08:49 -05:00
Martín Gaitán fb7dcfd62d Exclude codemirror
An example of a wrong detection due to codemirror is my project.  https://github.com/mgaitan/waliki
2014-11-18 20:17:15 -03:00
Brandon Keepers 719f6e876b Merge pull request #1732 from github/filename-matches-multiple-langages
Require samples if filename matches multiple languages
2014-11-18 16:31:19 -05:00
Brandon Keepers d7fd12cb32 Remove deprecated method 2014-11-18 15:19:23 -05:00
Brandon Keepers 850ab6dedb #all_extensions already includes primary extension 2014-11-18 15:10:07 -05:00
Brandon Keepers ac59620728 Remove blank extensions property 2014-11-18 14:48:43 -05:00
Lars Brinkhoff 03c1e725ce Add Forth extensions .f and .for; add heuristics for Forth and FORTRAN. 2014-11-18 20:21:19 +01:00
Brandon Keepers 757801e32f Merge remote-tracking branch 'origin/master' into filename-matches-multiple-langages
* origin/master:
  Allow mime-types 2.x to be used with Linguist
  Upgrade to rugged 0.22.0b1
  Mention that languages need to be quite popular
  fix vendor/cache
  Gemfile.lock is nolonger considered generated
  Tests for BlobHelper#empty?
  remove reference to empty.js
  Remove more empty samples
  Bail earlier if the file is empty.
  Moving comments
  Use heuristics earlier to inform the rest of the classification process
  Removing inconsistency of `find_by_heuristics` (was sometimes returning nil and sometimes returning and empty array)
  Removing unused array of candidate languages.
  Reworking most heuristics to only return one match
2014-11-18 14:09:15 -05:00
Arfon Smith 0443c4db2d Merge pull request #1674 from github/rework-heuristics
Rework heuristics
2014-11-18 10:43:01 -06:00
Brandon Keepers cd7549390e Extensions aren't actually required 2014-11-17 20:00:09 -05:00
Brandon Keepers 63c83d014b Fix errors from pedantic test 2014-11-17 18:53:14 -05:00
Arfon Smith c5344da2ba Removing extensions when they should be filenames 2014-11-17 16:44:39 -06:00
Arfon Smith 7d850d7c09 Gemfile.lock is nolonger considered generated 2014-11-17 16:31:47 -06:00
Brandon Keepers 6c106b88c0 Avoid using singular #extension 2014-11-17 15:47:21 -05:00
Brandon Keepers c46667581d Use the first extension with languages defined 2014-11-17 15:15:39 -05:00