post-receive-soupault (518B)
1 #!/bin/sh 2 3 title=' beauhilton ' 4 url='https://beauhilton.com' 5 6 dst="/var/www/htdocs/www.beauhilton.com" 7 raw="$dst/raw" 8 src="$dst/src" 9 10 if test -z "${PWD##*.git}" 11 then repo="$PWD" 12 else repo="$PWD/.git" 13 fi 14 15 echo $PWD 16 17 rm -rf "${dst:?}/.files" 18 rm -rf "$raw" 19 rm -rf "$src:?" 20 21 mkdir -p "$raw" 22 echo "${title}" > "$repo/owner" 23 git clone "$repo" "$raw" 24 (cd "$raw/.git" && git update-server-info) 25 26 cp -r $raw/build/** "$dst" 27 28 mkdir -p "$src" 29 (cd "$src" && stagit "$repo") 30 cp -f "$src/log.html" "$src/index.html"