summaryrefslogtreecommitdiff
path: root/bin/gitano-update-hook.in
diff options
context:
space:
mode:
authorDaniel Silverstone <dsilvers@digital-scurf.org>2012-09-01 10:28:19 +0100
committerDaniel Silverstone <dsilvers@digital-scurf.org>2012-09-01 10:28:19 +0100
commit22290b4a4d93ed7c36a84786551c65b9d36d336c (patch)
tree414156f315e468d42e11255c559983f2c31e681d /bin/gitano-update-hook.in
parentf12458c7194b61d66621fe1731c6bc21d54d18c4 (diff)
downloadgitano-22290b4a4d93ed7c36a84786551c65b9d36d336c.tar.gz
SUPPLE: Supply an actor table in the global namespace of each hook, containing info about the user
Diffstat (limited to 'bin/gitano-update-hook.in')
-rw-r--r--bin/gitano-update-hook.in9
1 files changed, 8 insertions, 1 deletions
diff --git a/bin/gitano-update-hook.in b/bin/gitano-update-hook.in
index 7658d0d..dd81649 100644
--- a/bin/gitano-update-hook.in
+++ b/bin/gitano-update-hook.in
@@ -255,7 +255,14 @@ if repo:uses_hook("update") then
gitano.log.debug("Configuring for update hook")
gitano.actions.set_supple_globals("update")
gitano.log.info("Running repository update hook")
- local ok, msg = gitano.supple.run_hook("update", repo,
+ local info = {
+ username = username,
+ keytag = keytag,
+ source = source,
+ realname = (config.users[username] or {}).real_name or "",
+ email = (config.users[username] or {}).email_address or "",
+ }
+ local ok, msg = gitano.supple.run_hook("update", repo, info,
refname, oldsha, newsha)
if not ok then
gitano.log.fatal(msg or "No reason given to refuse action.")