Questions tagged [github-linguist]

Linguist is a ruby library developed and used on GitHub.com to detect blob languages, ignore binary or vendored files, suppress generated files in diffs, and generate language breakdown graphs.

Linguist is a ruby library developed and used on GitHub.com to detect blob languages, ignore binary or vendored files, suppress generated files in diffs, and generate language breakdown graphs.

65 questions
4
votes
1 answer

Does GitHub Linguist support prefix wildcards for linguist-vendored?

In GitHub's documentation on linguist, the section on using the .gitattributes file says a path can be marked as vendored, and thus ignored in the repository's statistics tracking, with: special-vendored-path/* linguist-vendored However, is it…
user2943160
  • 507
  • 5
  • 12
4
votes
1 answer

Does github expose an API for linguist?

I looked through the github API docs and couldn't find an answer. Does github expose linguist information via any API endpoints? I'm looking to get languages associated with a repo, as detected by linguist.
mjgpy3
  • 8,597
  • 5
  • 30
  • 51
4
votes
1 answer

Github project languages (linguist) information not visible?

Normally you can see on top right what your project exists of, how much % PHP, how much % JS etc.. On my current project this is not visible, I have tried removing and adding it again on Github but without luck. It was originally forked from another…
wouterds
  • 881
  • 10
  • 26
3
votes
0 answers

No console output during call WSL/WSL2 command in Powershell from C#

I have Pengwin (Linux distro optimalized for working with WSL - surely everybody know) with installed github-linguist, set up by tutorial in https://github.com/github/linguist/blob/master/README.md . Even I have use my Insider Windows instance,…
3
votes
1 answer

Add multiple languages in .gitattributes file

I own a Github repository which has a collection of scripts/programs in different languages to perform a task. The problem is that by default, my repository is marked to be in single language. I googled and tried to fix it with the .gitattributes…
cht
  • 319
  • 3
  • 13
3
votes
1 answer

Github Linguist overrides with wildcard

I want to set some GitHub's Linguist overrides in my .gitattributes file, more specifically I want to remove some ".vb" files from being taken into an account for determining the language statistics: Solution 1/Vb/My Project/AssemblyInfo.vb Solution…
Kipper
  • 21
  • 8
3
votes
2 answers

Get repository languages with the GitLab API

I would like to know if there is a way to get the languages (percentage per language) used in a project by using the API provided by GitLab. I checked their documentation but I didn't see anything about that or maybe I missed it. I know that they…
3
votes
2 answers

Is There Any Way to Disable Error Highlighting in Github?

Github highlights the second % in this line as an error: fscanf(fp, "%d%*[^\n]\n", &ints[i]); However, the code compiles perfectly and the removing the 'error' will cause the program to function incorrectly. Is there any way to either disable this…
3
votes
2 answers

How can I detect the programming language of a snippet?

I have a string containing some text. The text may or may not be code. Using Github's Linguist, I have been able to detect the likely programming language only if I give it a list of candidates. # test_linguist_1.rb #!/usr/bin/env ruby require…
Martin Velez
  • 1,379
  • 11
  • 24
3
votes
1 answer

Could not create Makefile for some reason - Trying to install Ruby Gem

I'm having some trouble installing a Ruby Gem called Lingust for my Mac. I get the error message below and have no idea how to solve the issue. Any help would be greatly appreciated. gem install github-linguist Building native extensions. This…
Kanery
  • 91
  • 2
  • 10
2
votes
1 answer

.gitattributes for linguist doesn't work correctly with gitlab

I have a (private) project on Gitlab which uses GameMaker, and the .yy files were being detected as Yacc. I looked up how to change this, so I came across .gitattributes files, as described here and here. I created a .gitattributes file in the…
Tajoshu
  • 47
  • 10
2
votes
1 answer

Github Repo is not showing the Language Bar as well as most used Language

My github repo is not showing the language statistics [in the form of the bar under 'packages'] and the most used language. I've done some testing with the same files and it seems like Github's Linguist just starts to break after a couple of…
2
votes
1 answer

Github: linguist-generated=true not working in .gitattributes

I am storing all the generated files in the build folder and trying to ignore these files in the pull request, I found and used the following method for doing so: 1.Create a .gitattributes file in the root directory. 2.Add this code to…
Odasaku
  • 177
  • 6
  • 17
2
votes
1 answer

GitHub overriding markup language?

I'm using a markup language called AsciiDoc (*.adoc). I'd like to name my *.adoc files as *.txt [^1]. However, then GitHub (of course) doesn't draw .txt files as .adoc files. So I tried to override the file types using .gitattributes as this: *.txt…
toyboot 4e
  • 23
  • 1
  • 3
2
votes
3 answers

When commiting to GitHub, where should 3rd party libraries like jQuery be stored to not affect the language stats?

I want to include the actual jQuery code in my project somewhere, but I want GitHub to ignore the content of the 3rd party files.