X-Git-Url: https://git.armaanb.net/?a=blobdiff_plain;f=repo-gen.sh;h=1a22f85e1d4771d81cbb99e17f2b44696444369e;hb=26d169681c44e1189769087074d7b9f15a665c20;hp=f74e02f0b416ef2e41a7b024ca9e698eb53c2d01;hpb=c4f46c3f9ccded868ccc32b2aaac89cf40d9b196;p=stagit.git diff --git a/repo-gen.sh b/repo-gen.sh index f74e02f..1a22f85 100755 --- a/repo-gen.sh +++ b/repo-gen.sh @@ -6,14 +6,14 @@ for arg in "$@"; do [ "$arg" = "--fresh" ] && fresh=true done -STAGIT=/var/www/git/stagit +STAGIT=/var/www/git/stagit.out [ ! -f "$STAGIT" ] && STAGIT=stagit -STAGIT_INDEX=/var/www/git/stagit-index +STAGIT_INDEX=/var/www/git/stagit-index.out [ ! -f "$STAGIT_INDEX" ] && STAGIT_INDEX=stagit-index for repo in /srv/git/*.git; do - repo="$(basename "$repo" | cut -f 1 -d '.')" + repo="$(basename "$repo" | rev | cut -c 5- | rev)" [ "$fresh" = true ] \ && echo "Deleting HTML for $repo." \ @@ -27,7 +27,10 @@ for repo in /srv/git/*.git; do echo "git://git.knutsen.co/$repo" > "/srv/git/$repo.git/url" - "$STAGIT" "/srv/git/$repo.git" + COMMAND="$STAGIT /srv/git/$repo.git" + echo "$COMMAND" + $COMMAND done +echo "Generating index.html with \`$STAGIT_INDEX\`." "$STAGIT_INDEX" /srv/git/*.git > /var/www/git/index.html