mirror of
git://git.acid.vegas/random.git
synced 2024-12-04 13:36:39 +00:00
Update
This commit is contained in:
parent
dc9f20b3c8
commit
79ab544a09
@ -1,14 +0,0 @@
|
||||
#!/bin/sh
|
||||
# note: place this file in GITREPO/.git/hooks/post-commit && chmod +x
|
||||
_data=$(git log -1 --graph --pretty=format:"%h|%s|%cn")
|
||||
_hash=$(echo "$_data" | cut -d'|' -f1 | cut -c 3-)
|
||||
_msg=$(echo "$_data" | cut -d'|' -f2)
|
||||
#_name=$(echo "$_data" | cut -d'|' -f3)
|
||||
_name=$(basename $(dirname $(git rev-parse --show-toplevel))) # Local hack to parse out ircart/supernets organizations
|
||||
_repo=$(basename -s .git $(git config --get remote.origin.url))
|
||||
_summary=$(git show $_hash --stat | grep -E "fil(e|es) changed" | awk '{files+=$1; inserted+=$4; deleted+=$6} END {printf "%s|+%s|-%s", files, inserted, deleted }')
|
||||
_files=$(echo $_summary | cut -d'|' -f1)
|
||||
_inserts=$(echo $_summary | cut -d'|' -f2)
|
||||
_deletes=$(echo $_summary | cut -d'|' -f3)
|
||||
_ircmsg="irc.supernets.#superbowl *14[11GitHub14] Commit pushed to 08$_name/$_repo (06$_hash) 14[$_files14|03$_inserts14|04$_deletes14] : $_msg"
|
||||
echo "$_ircmsg" | ssh contra tee "$HOME/.weechat/weechat_fifo" > /dev/null
|
Loading…
Reference in New Issue
Block a user