6 [ "$arg" = "--fresh" ] && fresh=true
9 STAGIT=/var/www/git/stagit
10 [ ! -f "$STAGIT" ] && STAGIT=stagit
12 STAGIT_INDEX=/var/www/git/stagit-index
13 [ ! -f "$STAGIT_INDEX" ] && STAGIT_INDEX=stagit-index
15 for repo in /srv/git/*.git; do
16 repo="$(basename "$repo" | cut -f 1 -d '.')"
19 && echo "Deleting HTML for $repo." \
20 && rm -fr "/var/www/git/$repo"
21 mkdir -p "/var/www/git/$repo"
22 cd "/var/www/git/$repo"
24 [ ! -f style.css ] && ln -s ../style.css ./
25 [ ! -f favicon.png ] && ln -s ../favicon.png ./
26 [ ! -f logo.png ] && ln -s ../logo.png ./
28 echo "git://git.knutsen.co/$repo" > "/srv/git/$repo.git/url"
30 "$STAGIT" "/srv/git/$repo.git"
33 "$STAGIT_INDEX" /srv/git/*.git > /var/www/git/index.html