Github - Stone Html/CSS 文件没有更改语言统计

Github - Store Html/CSS file without change langage stats

我在 Crystal 上制作了一个小爬虫,托管于 Github。我想存储网站 HTML 用于测试目的,但是当我这样做时,我的 Github 项目显示为 Html (因为HTML 的数量与 Crystal 行的数量相比)

如何"ignore" 论文 Html 个文件?

我认为您无法控制 github 将您的项目识别为哪种语言。

您绝对可以使用 .gitignore (https://git-scm.com/docs/gitignore) 忽略 html 文件,但您实际上会忽略这些文件,它们不会出现在您的 github 存储库。

我发现存储在项目根目录 doc/docs/ 文件夹中的 HTML/CCS 文件不会影响存储库语言统计信息。

开源 Linguist project is in charge of computing language statistics for repositories. You can use Linguist overrides 更改其检测输出。

特别是,您可能希望在 .gitattributes 文件中添加以下行:

*.html linguist-vendored
*.css linguist-vendored