github - GitHub Linguist 是否支持linguist-vendored 的前缀通配符?

标签 github github-linguist

linguist 上的 GitHub 文档中, section关于使用 .gitattributes文件说一个路径可以被标记为vendored,因此在存储库的统计跟踪中被忽略,具有:

special-vendored-path/* linguist-vendored

但是,是否可以将语言学家标记为可嵌套在包含非供应商代码的目录中的供应商目录?

我尝试添加样式为 */special-vendored-path/* linguist-vendored 的线条到我的 .gitattributes ,但这并没有导致 GitHub 代码比例信息发生变化。

最佳答案

要匹配任意目录树中的目录,您需要 双星号 :

**/special-vendored-path/* linguist-vendored

但是请注意,路径末尾不需要双星号。例如,test1/*将匹配 test1/test2/test3/file .

关于github - GitHub Linguist 是否支持linguist-vendored 的前缀通配符?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39060111/

相关文章:

GitHub 将存储库更改为错误的语言

Github 项目语言(语言学家)信息不可见?

github - 在 GitHub 上更改存储库语言

git - 是否可以在 GitHub 存储库上定义自己的语法?

import - 将 Plastic SCM 与公共(public)代码托管服务结合使用的工作流程

github - 身份验证被删除。请改用个人访问 token

git - 如何从 android.googlesource.com 或 github.com 下载单个目录?

python - 在操作中克隆组织内的私有(private) github 存储库

git - 如何忽略 git 中现有的已提交文件?

javascript - 当提交到 GitHub 时,像 jQuery 这样的第三方库应该存储在哪里才不会影响语言统计数据?