From 582daf273a4b0442c0a5c8f76884c6c5ed81cad1 Mon Sep 17 00:00:00 2001 From: Wade Tandy Date: Mon, 23 Dec 2013 21:36:55 -0500 Subject: [PATCH] Add vendor patterns for bower_components files Adds Bower Component files to the vendored files list. This uses the `bower_components` directory, which is the standard set by the Bower package manager. --- lib/linguist/vendor.yml | 3 +++ test/test_blob.rb | 7 ++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/linguist/vendor.yml b/lib/linguist/vendor.yml index 048f3689..5161eb7f 100644 --- a/lib/linguist/vendor.yml +++ b/lib/linguist/vendor.yml @@ -27,6 +27,9 @@ # Node dependencies - node_modules/ +# Bower Components +- bower_components/ + # Erlang bundles - ^rebar$ diff --git a/test/test_blob.rb b/test/test_blob.rb index b4ff61ea..54200c3c 100644 --- a/test/test_blob.rb +++ b/test/test_blob.rb @@ -224,6 +224,11 @@ class TestBlob < Test::Unit::TestCase # Node dependencies assert blob("node_modules/coffee-script/lib/coffee-script.js").vendored? + # Bower Components + assert blob("bower_components/custom/custom.js").vendored? + assert blob("app/bower_components/custom/custom.js").vendored? + assert blob("vendor/assets/bower_components/custom/custom.js").vendored? + # Rails vendor/ assert blob("vendor/plugins/will_paginate/lib/will_paginate.rb").vendored? @@ -326,7 +331,7 @@ class TestBlob < Test::Unit::TestCase # Test fixtures assert blob("test/fixtures/random.rkt").vendored? assert blob("Test/fixtures/random.rkt").vendored? - + # Cordova/PhoneGap assert blob("cordova.js").vendored? assert blob("cordova.min.js").vendored?