From: danix Date: Sun, 26 Apr 2020 19:16:05 +0000 (+0200) Subject: nuovo file: .gitignore X-Git-Url: https://git.danix.xyz/?a=commitdiff_plain;h=refs%2Fheads%2Fmaster;p=git_shell.git nuovo file: .gitignore nuovo file: edit --- diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1c17649 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +.*.un~ +*~ diff --git a/edit b/edit new file mode 100644 index 0000000..31fd8d5 --- /dev/null +++ b/edit @@ -0,0 +1,23 @@ +#! /bin/bash + +# usage: edit - edit a git repository named PROJECT.git +# this command will edit some settings for the repo and send an email. + +GITDIR="/var/git" + +function is_bare() { + repodir=$1 + if "$(git --git-dir="$repodir" rev-parse --is-bare-repository)" = true + then + true + else + false + fi +} + +function edit_desc() { + PROJECT=$1 + echo "modifying description for \"${PROJECT}.git\"" + echo -n "Describe your project in one line: " + read DESCRIPTION + cd ${GITDIR}/${PROJECT}.git