0

Prevent-Public-Repos Probot App 不将 repo 更改为 private

到目前为止,我已经调整了参数并测试了各种值组合。从我的 Github Enterprise 帐户(我们使用云)上可以看到,有一个新的内部存储库状态——不再是公共/私有。我想知道这是否会破坏 API 调用以将此存储库更改回私有。


# Turn on Monitor Mode. In this mode the repo visibility is not modified and only an Issue is created
monitorOnly: false

# Enables detection of repos that change visibility from private to public (not just newly created ones)
enablePrivateToPublic: false

我们收到了一些问题,提醒我们测试存储库的状态从私有更改为公共。最后一个方法 changeVisibility() 似乎没有正确执行。

4

1 回答 1

0

我终于想通了,并在项目上创建了一个问题。https://github.com/issc29/probot-prevent-public-repos/issues/14

对于那些不想点击上述票证的人的修改答案。

  1. 我需要启用谁可以调整组织的存储库可见性,这不在说明 README.md 中,用于设置此项目,并且可能应该列为入门中的一个步骤,并带有某种类型的提及,例如, “验证在成员权限中选择了‘允许成员更改此组织的存储库可见性’的权限”
  2. enablePrivateToPublic: false 的值应设置为 true 而不是 false。这一行上面的文字有点混乱。它应该得到澄清,或者可能改变这个变量的名称,这会破坏向后兼容性。也许添加额外的评论来澄清,例如:
# Enables detection of repos that change visibility from private to public (not just newly created ones)
# true -- will prevent a Private repo from transitioning to Public scope, unless this repository is listed in the excludeRepos list below
# false -- will allow a Private repo to transition to Public scope and only create an issue about this transition
于 2019-06-19T14:11:12.280 回答