Skip to content

Commit

Permalink
backlog(1.0): 添加update方法
Browse files Browse the repository at this point in the history
提供git toolkit update来直接更新本工具集
  • Loading branch information
tonydeng committed Sep 29, 2016
1 parent 2b4c01d commit 3091d6e
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion installer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ function uninstall() {

# 使用帮助
function help() {
echo "Usage: [environment] $REPO_NAME installer.sh [install|uninstall]"
echo "Usage: [environment] $REPO_NAME installer.sh [install|uninstall|update]"
echo "Environment:"
echo " COMMAND_PATH_PREFIX=$COMMAND_PATH_PREFIX"
echo " INSTALL_PATH=$INSTALL_PATH"
Expand All @@ -66,6 +66,11 @@ function install() {
install_hooks
}

function update() {
echo "Update $REPO_NAME"
install
}

# clone项目
function clone() {
if [ -d "$INSTALL_PATH" -a -d "$INSTALL_PATH/.git" ] ; then
Expand Down Expand Up @@ -114,6 +119,10 @@ case $1 in
uninstall
exit
;;
update)
update
exit
;;
help)
help
exit
Expand Down

0 comments on commit 3091d6e

Please sign in to comment.