0

Github's linguist is detecting many files in my repos which are vendored, especially JavaScript. I found out that a .gitattributes can be used to configure linguist to ignore several files for statistics count.

But this doesn't work, in any way I try. It seems like it simply doesn't matter whats defined in my .gitattributes. So far, I've tried the following:

deploy/static/js/pdfjs/*    linguist-vendored
deploy/static/py/Brython-3.7.1/*    linguist-vendored

deploy/static/js/pdfjs/build/pdf.js linguist-vendored
deploy/static/js/pdfjs/web/debugger.js  linguist-vendored
deploy/static/js/pdfjs/web/viewer.js    linguist-vendored
deploy/static/py/Brython-3.7.1/brython.js   linguist-vendored

/deploy/static/js/pdfjs/*   linguist-vendored
/deploy/static/py/Brython-3.7.1/*   linguist-vendored

**/pdfjs/*  linguist-vendored
**/Brython-3.7.1/*  linguist-vendored

The result when I run github-linguist --breakdown is always

JavaScript:
deploy/static/js/app.js
deploy/static/js/pagination.js
deploy/static/js/pdfjs/build/pdf.js
deploy/static/js/pdfjs/web/debugger.js
deploy/static/js/pdfjs/web/viewer.js
deploy/static/py/Brython-3.7.1/brython.js
sources/gulpfile.js

What am I doing wrong?

glasflügel
  • 325
  • 2
  • 11
  • 1
    I've run `git check-attr` now on file `deploy/static/py/Brython-3.7.1/brython.js` and it gives me $ git check-attr -a deploy/static/py/Brython-3.7.1/brython.js deploy/static/py/Brython-3.7.1/brython.js: linguist-vendored: set So the attributes seem to be set. – glasflügel Jan 25 '20 at 09:16
  • What's the repository's URL? – pchaigno Jan 25 '20 at 11:36

0 Answers0