From f522fb4f17114d48e2de5b60a9b34dea350e77cb Mon Sep 17 00:00:00 2001 From: Syndamia Date: Sat, 31 Oct 2026 11:01:59 +0200 Subject: feat!: Initial setup --- scripts/new | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100755 scripts/new (limited to 'scripts/new') diff --git a/scripts/new b/scripts/new new file mode 100755 index 0000000..65e677a --- /dev/null +++ b/scripts/new @@ -0,0 +1,20 @@ +#!/bin/bash + +while [ -z "$1" ] +do + printf 'Repository: ' + read + set "$REPLY" +done + +set "${1##/}" + +root_dir="${1%%/*}" +repo_dir="${1#*/}" + +cd "$root_dir" +if git init --bare "$repo_dir" +then + echo -e "\nClone repo with:\n\tgit clone git@syndamia.com:$1" + echo -e "\nUpload local repo with:\n\tgit push git@syndamia.com:$1 '*:*'" +fi -- cgit v1.3.1-23-gd82d