echo "Need init state to be either 'copy' or 'new' or 'upgrade'"
false
fi
-if [ ! "$4" = "new" ] and [ "$#" -ne 5 ]; then
+if [ ! "$4" = "new" ] && [ "$#" -ne 5 ]; then
echo "With init state != 'new' need fifth argument old server IP."
false
fi
# This assumes the old core.plomlompom.com filesystem hierarchy.
su -lc "cd /var/repos && git clone --mirror ${old_server}:repos/website" plom
elif [ "${init_state}" = "new" ]; then
- su -lc "cd /var/repos && git init --bare website" plom
+ su -lc "cd /var/repos && git init --bare website.git" plom
fi
# TODO: find out whether this can be part of cloned repo …?
cp "${config_tree_prefix}/other_files/website_hook_post-receive" /var/repos/website.git/hooks/post-receive