Compare commits

...

3 Commits

Author SHA1 Message Date
Brandon Black
9fe5fe0de2 v5.0.3 Release (#3436)
* bumping to v5.0.3

* updating grammars
2017-01-23 20:09:26 -08:00
sunderls
b36ea7ac9d Add yarn (#3432)
* add yarn.lock

* fix comment

* remove yarn test

* add test

* fix test

* try fix again

* try 3rd time

* check filename and firstline for yarn lockfile
2017-01-23 10:58:53 -08:00
Yuki Izumi
625b06c30d Use textmate/diff.tmbundle again (#3429)
Upstream textmate/diff.tmbundle#6 was merged.
2017-01-17 17:02:10 +11:00
22 changed files with 41 additions and 20 deletions

2
.gitmodules vendored
View File

@@ -249,7 +249,7 @@
url = https://github.com/textmate/d.tmbundle
[submodule "vendor/grammars/diff.tmbundle"]
path = vendor/grammars/diff.tmbundle
url = https://github.com/kivikakk/diff.tmbundle
url = https://github.com/textmate/diff.tmbundle
[submodule "vendor/grammars/dylan.tmbundle"]
path = vendor/grammars/dylan.tmbundle
url = https://github.com/textmate/dylan.tmbundle

View File

@@ -80,7 +80,8 @@ module Linguist
generated_jflex? ||
generated_grammarkit? ||
generated_roxygen2? ||
generated_jison?
generated_jison? ||
generated_yarn_lock?
end
# Internal: Is the blob an Xcode file?
@@ -479,5 +480,13 @@ module Linguist
return lines[0].start_with?("/* parser generated by jison ") ||
lines[0].start_with?("/* generated by jison-lex ")
end
# Internal: Is the blob a generated yarn lockfile?
#
# Returns true or false.
def generated_yarn_lock?
return false unless name.match(/yarn\.lock/)
return lines[0].include?("# THIS IS AN AUTOGENERATED FILE")
end
end
end

View File

@@ -1,3 +1,3 @@
module Linguist
VERSION = "5.0.2"
VERSION = "5.0.3"
end

9
test/fixtures/Data/yarn.lock vendored Normal file
View File

@@ -0,0 +1,9 @@
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1
abab@^1.0.0:
version "1.0.3"
resolved "https://registry.yarnpkg.com/abab/-/abab-1.0.3.tgz#b81de5f7274ec4e756d797cd834f303642724e5d"
abbrev@1, abbrev@1.0.x:
version "1.0.9"
resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz#91b4792588a7738c25f35dd6f63752a2f8776135"

View File

@@ -79,6 +79,9 @@ class TestGenerated < Minitest::Test
generated_fixture_loading_data("Data/sourcemap.v3.map")
generated_fixture_loading_data("Data/sourcemap.v1.map")
# Yarn locfile
generated_fixture_loading_data("Data/yarn.lock")
# Specflow
generated_fixture_without_loading_data("Features/BindingCulture.feature.cs")