11e0ea6b |
1 | #! /bin/bash |
2 | |
3 | # usage: edit <PROJECT> - edit a git repository named PROJECT.git |
4 | # this command will edit some settings for the repo and send an email. |
5 | |
6 | GITDIR="/var/git" |
7 | |
8 | function is_bare() { |
9 | repodir=$1 |
10 | if "$(git --git-dir="$repodir" rev-parse --is-bare-repository)" = true |
11 | then |
12 | true |
13 | else |
14 | false |
15 | fi |
16 | } |
17 | |
18 | function edit_desc() { |
19 | PROJECT=$1 |
20 | echo "modifying description for \"${PROJECT}.git\"" |
21 | echo -n "Describe your project in one line: " |
22 | read DESCRIPTION |
23 | cd ${GITDIR}/${PROJECT}.git |