Commit 6aea7840 authored by Vitaly Lipatov's avatar Vitaly Lipatov

ginit: small cleanup

parent ef0edad8
......@@ -7,7 +7,7 @@ load_mod git
if [ "$1" = "-h" ] || [ "$1" = "--help" ]; then
echo "ginit - initialize repo in $GIRARHOST for current project"
echo "Use: ginit [GIRAR]"
echo " ginit git.eter - for init in git.eter gear repo"
echo " ginit git.eter - for create repo in the git.eter"
exit 1
fi
......@@ -16,14 +16,12 @@ if is_girar_name $1 ; then
shift
fi
test -r "$1" && fatal "Do not need any files in params"
test -r "$1" && fatal "Do not need any params more"
PROJECTNAME=$(get_gear_name)
RPNAME=$(get_gear_name)
# FIXME: если не нашли, стоит взять название каталога за основу
[ -n "$PROJECTNAME" ] || fatal "Can't detect project name. Run inside git repo."
RPNAME=$(echo $PROJECTNAME | filter_gear_name)
[ -n "$RPNAME" ] || fatal "Can't detect project name. Run inside git repo."
echo "Create remote $RPNAME repo in $GIRARHOST:"
docmd ssh $GIRARHOST git-init-db "$RPNAME.git"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment