0

Github is not showing language bar for the repository. Repository link : https://github.com/Hiteshk369/Weather-APP

My repo consists of three files Html, Css and Js. Help me in fixing this problem!

I tried finding the solution for the problem from different sources like yt, medium and even stack overflow and failed to find a solution. I want my repo to have the language bar.

2 Answers2

1

If linguist didn't detect your language such as SQL you can simply use the line below in a file that is named as ".gitattributes" in your repository.

*.sql linguist-detectable=true

For ruby you can add this attribute to mark it as Ruby.

*.rb linguist-language=Java

You can find more on the link below.

Using gitattributes for linguist examples

0

Your project is very basic, so it is probably being picked-up as "generated code" by Linguist.

Mentioned in GitHub Docs: About repository languages?

Some files are hard to identify, and sometimes projects contain more library and vendor files than their primary code. If you're receiving incorrect results, please consult the Linguist troubleshooting guide for help. Note that Linguist only works for repositories with fewer than 100,000 files.

Here is the troubleshooting excerpt:

My repository isn't showing my language

Linguist does not consider vendored code, generated code, documentation, or data (e.g. SQL) or prose (e.g. Markdown) languages (as defined by the type attribute in languages.yml) when calculating the repository language statistics.

If the language statistics bar is not showing your language at all, it could be for a few reasons:

  1. Linguist doesn't know about your language.
  2. The extension you have chosen is not associated with your language in languages.yml.
  3. All the files in your repository fall into one of the categories listed above that Linguist excludes by default.

If Linguist doesn't know about the language or the extension you're using, consider contributing to Linguist by opening a pull request to add support for your language or extension. For everything else, you can use the manual overrides feature to tell Linguist to include your files in the language statistics.

Mr. Polywhirl
  • 42,981
  • 12
  • 84
  • 132