Search code examples
c++githubd

Github incorrectly recognizes programming language used in the project


So I have a git repository that I wrote in C++, but github insists that I'm using D. Why is this and is there someway to correct it?


Solution

  • Github uses it's own language parsing module and sometimes (actually often) it makes faults. Just write more code to make it easier for parser to choose what your main language is and after some time github will get it right.

    In this particular case code parser is fooled by your files in STMC-C/Assignments/a* dirs with .d extension. That's an extension for D sources. The number of this sources dominated in your project so github decided that the main programming language used is D.

    edit: Just found this public repo (github language detector) - it has some explanations of the system.