如何在gh repo create cli命令中指定--gitignore参数



我正试图使用GitHub CLI创建远程存储库,但我找不到如何使用参数--gitignore(例如github/gitignore/C++.gitignore(指定特定的gitignore文件。HTTP 422: Repository creation failed. (https://api.github.com/user/repos) gitignore_template is an unknown gitignore template.出现错误

一直试图在互联网上找到一个例子,但没有成功。

此功能是在PR 3746中为gh v1.12.0(2021年第二季度(实现的。

它应该只使用一个单词作为gitignore参数
示例:

gh repo create random --gitignore Go --license mit --public --confirm 

在您的情况下,请尝试--gitignore C++--gitignore Cpp

最新更新