tcreate-repo.sh: create https alternate url - stagit - [fork] customized build of stagit, the static git page generator
 (HTM) git clone git://src.adamsgaard.dk/stagit
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit 308c83741eabd65b8d4362b81fe6ab5ac5011e81
 (DIR) parent a2d4b09c789089503396bae1f1206d06f35cdc70
 (HTM) Author: Anders Damsgaard <anders@adamsgaard.dk>
       Date:   Sat, 28 Nov 2020 00:42:08 +0100
       
       create-repo.sh: create https alternate url
       
       Diffstat:
         M create-repo.sh                      |      10 ++++++----
       
       1 file changed, 6 insertions(+), 4 deletions(-)
       ---
 (DIR) diff --git a/create-repo.sh b/create-repo.sh
       t@@ -5,6 +5,7 @@ set -eu
        repodir="$HOME"
        default_owner="Anders Damsgaard"
        giturl="git://src.adamsgaard.dk"
       +altgiturl="https://src.adamsgaard.dk"
        
        [ $# -lt 1 ] && (echo "usage: $0 repo_name" && exit 1)
        
       t@@ -12,14 +13,15 @@ curdir="$(pwd)"
        cd "$repodir"
        for r in "$@"; do
                git init --bare "$r"
       -        printf "description for $r: "
       -        read -r REPLY
       +        printf 'description for %s: ' "$r"
       +        read
                echo "$REPLY" > "$r"/description
                printf "owner [$default_owner]: "
       -        read -r REPLY
       +        read
                echo "${REPLY:-$default_owner}" > "$r"/owner
       -        ln -s ../../post-receive.sh "$r"/hooks/post-receive
       +        ln -sf ../../post-receive.sh "$r"/hooks/post-receive
                echo "${giturl}/${r}" > "$r"/url
       +        echo "${altgiturl}/${r}.git" > "$r"/alturl
                touch "$r"/git-daemon-export-ok
        done