关于仓库可见性更改
组织所有者可以限制只有组织所有者才能更改仓库可见性。 更多信息请参阅“限制组织的仓库可见性更改”。
我们建议在您更改仓库可见性之前审查以下注意事项。
将仓库设为私有
- GitHub 将会分离公共仓库的公共复刻并将其放入新的网络中。 公共复刻无法设为私有。 If you change a repository's visibility from internal to private, GitHub will remove forks that belong to any user without access to the newly private repository. For more information, see "What happens to forks when a repository is deleted or changes visibility?"
- Anonymous Git read access is no longer available. For more information, see "Enabling anonymous Git read access for a repository."
将仓库设为公共
- GitHub 将会分离私有复刻并将它们变成独立的私有仓库。 更多信息请参阅“删除仓库或更改其可见性时,复刻会发生什么变化?”
- If you're converting your private repository to a public repository as part of a move toward creating an open source project, see the Open Source Guides for helpful tips and guidelines.
将仓库设为私有
- 在 GitHub Enterprise 上,导航到仓库的主页面。
- 在仓库名称下,单击 Settings(设置)。

- 在“Danger Zone(危险区域)”下“Make this repository private(将此仓库设为私有)”旁边,单击 Make private(设为私有)。

- 阅读关于将仓库设为私有的警告。

- 输入您要设为私有的仓库的名称,例如
accountname/reponame。 - 单击 I understand, make this repository private(我已了解,请将此仓库设为私有)。
将仓库设为公共
- 在 GitHub Enterprise 上,导航到仓库的主页面。
- 在仓库名称下,单击 Settings(设置)。

- 在“Danger Zone(危险区域)”下“Make this repository public(将此仓库设为公共)”旁边,单击 Make public(设为公共)。

- 阅读关于将仓库设为公共的警告。

- 输入您要设为公共的仓库的名称,例如
accountname/reponame。 - 单击 I understand, make this repository public(我已了解,请将此仓库设为公共)。
将仓库设为内部
- 在 GitHub Enterprise 上,导航到仓库的主页面。
- 在仓库名称下,单击 Settings(设置)。

- 在“Danger Zone(危险区域)”下“Make this repository internal(将此仓库设为内部)”旁边,单击 Make internal(设为内部)。

- 阅读关于将仓库设为内部的警告。

- 输入您要设为内部的仓库的名称,例如
accountname/reponame。 - 单击 I understand, make this repository internal(我已了解,请将此仓库设为内部)。
延伸阅读
- "关于仓库可见性"