我正在尝试让 ACL 在 Mercurial 中工作。现在,我不确定它是否会起作用,因为我使用的是 hg 1.5.1。(我正在努力弄清楚我必须与谁交谈才能让某人为我升级它)
假设 1.5.1 将支持它,我的 hgrc 文件如下所示:
[extensions]
acl =
[hooks]
# Use this if you want to check access restrictions at commit time
pretxncommit = python:hgext.acl.hook
# Use this if you want to check access restrictions for pull, push,
# bundle and serve.
pretxnchangegroup = python:hgext.acl.hook
[acl]
# Check whether the source of incoming changes is in this list where
# "serve" == ssh or http, and "push", "pull" and "bundle" are the
# corresponding hg commands.
sources = serve push pull
ETC
我越来越:
error: pretxnchangegroup hook failed: acl: access denied for changeset 242c80d5c009
transaction abort!
rollback completed
abort: acl: access denied for changeset 242c80d5c009
目前,我只是在一个小型的非服务器 repo 上执行此操作,但最终这将在一个普通的大型 HTTPS 服务器上...
谢谢
编辑:[更改 hgrc 文件] 好的,现在我似乎在那里 1/2。当我尝试推动我不允许的分支时,我得到:
error: pretxnchangegroup.acl hook failed: acl: user "brian_postow" not allowed on branch "branch-b" (changeset "597eddef10a1")
transaction abort!
rollback completed
abort: acl: user "brian_postow" not allowed on branch "branch-b" (changeset "597eddef10a1")
哪个看起来正确(也许?)但是,当我从允许的分支推送时,我得到:
error: pretxnchangegroup.acl hook failed: acl: access denied for changeset 242c80d5c009
transaction abort!
rollback completed
abort: acl: access denied for changeset 242c80d5c009
所以,我似乎仍然无法推动......有什么想法吗?