Update git hook with DNS record and clean up comments
This commit is contained in:
parent
24e542c242
commit
2f6c90420e
|
@ -1,29 +1,40 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
# for use with gitolite
|
|
||||||
#
|
#
|
||||||
# http://sitaramc.github.com/gitolite/hooks.html
|
# This Git hook sends update message to a notification server, so
|
||||||
# copy this file to
|
# that manual git pushes to a repository also will be noticed by
|
||||||
# .gitolite/hooks/common/post-update
|
# SparkleShare clients.
|
||||||
# run gl-setup again
|
#
|
||||||
|
# For information on running your own notification service:
|
||||||
# for use with standard ssh/http(s)/git repos
|
# https://github.com/hbons/fanout.node.js
|
||||||
|
#
|
||||||
|
#
|
||||||
|
# For use with Gitolite:
|
||||||
|
#
|
||||||
|
# Copy this file to .gitolite/hooks/common/post-update.
|
||||||
|
# Run "gl-setup" again.
|
||||||
|
#
|
||||||
|
#
|
||||||
|
# For use with standard Git repositories:
|
||||||
|
#
|
||||||
|
# Copy this file to .git/hooks/post-update in
|
||||||
|
# the remote repository
|
||||||
|
#
|
||||||
|
#
|
||||||
|
# Make sure to "chmod -x" this hook after the file has been copied
|
||||||
#
|
#
|
||||||
# simply move this file to
|
|
||||||
# .git/hooks/post-update in the remote repository
|
|
||||||
|
|
||||||
# make sure to chmod -x in all cases after the file has been copied
|
# Change these if you run your own service somewhere
|
||||||
|
SERVER = "notifications.sparkleshare.org"
|
||||||
|
PORT = "1986"
|
||||||
|
|
||||||
#To supress all output
|
# Don't edit below this line
|
||||||
exec > /dev/null 2>&1
|
exec > /dev/null 2>&1
|
||||||
|
|
||||||
# for information on running your own server
|
CHANNEL = $(git rev-list --reverse HEAD | head -n 1)
|
||||||
# https://github.com/hbons/fanout.node.js
|
MESSAGE = $(git rev-list HEAD | head -n 1)
|
||||||
SERVER="204.62.14.135"
|
|
||||||
PORT="1986"
|
DATA = "announce ${CHANNEL} ${MESSAGE}"
|
||||||
CHANNEL=$(git rev-list --reverse HEAD | head -n 1)
|
|
||||||
MESSAGE=$(git rev-list HEAD | head -n 1)
|
|
||||||
DATA="announce ${CHANNEL} ${MESSAGE}"
|
|
||||||
echo "${DATA}\n" | socat - TCP-CONNECT:${SERVER}:${PORT} &
|
echo "${DATA}\n" | socat - TCP-CONNECT:${SERVER}:${PORT} &
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
|
|
Loading…
Reference in a new issue