diff options
author | Haoran S. Diao <0@hairydiode.xyz> | 2019-02-11 18:16:20 -0500 |
---|---|---|
committer | Haoran S. Diao <0@hairydiode.xyz> | 2019-02-11 18:16:20 -0500 |
commit | cd8be903f60a87283a7ca8e67d4378641594a6a1 (patch) | |
tree | 0cf9fdf08c75087a9cd81473d3fe5cb9b0247de1 | |
parent | e67907e91de880d6a4bdcdf88d69419940d1db1c (diff) |
added description editing feature
-rwxr-xr-x | mkgit-server | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/mkgit-server b/mkgit-server index 868cb21..241064b 100755 --- a/mkgit-server +++ b/mkgit-server @@ -1,11 +1,17 @@ #!/bin/bash if [ "$2" == "" ]; then - echo usage: mkgit-server [repository name] [git user] + echo usage: mkgit-server [repository name] [git user] [-d] + echo " -d; edit the description file instead" exit fi +if [ "$3" == "-d"]; then + $EDITOR /home/$2/$1description +fi mkdir /home/$2/$1.git cd /home/$2/$1.git git init --bare +echo "This is the description of the Repo" > description +$EDITOR description chown -R $2 * cd .. chown -R $2 $1.git |