diff --git a/src/freedombone-app-gogs b/src/freedombone-app-gogs index 3c31ed5f..3c2854e1 100755 --- a/src/freedombone-app-gogs +++ b/src/freedombone-app-gogs @@ -120,6 +120,9 @@ function upgrade_gogs { mkdir -p ${INSTALL_DIR} fi cd ${INSTALL_DIR} + if [ -d $INSTALL_DIR/gogs ]; then + rm -rf $INSTALL_DIR/gogs + fi GOGS_FILE=linux_${CURR_ARCH}.tar.gz if [ ! -f $GOGS_FILE ]; then wget ${GOGS_BIN} @@ -134,7 +137,7 @@ function upgrade_gogs { exit 37836 else apt-get -y install unzip - unzip -A ${GOGS_FILE} + unzip ${GOGS_FILE} fi else tar -xzf ${INSTALL_DIR}/${GOGS_FILE} @@ -351,6 +354,9 @@ function install_gogs { mkdir -p ${INSTALL_DIR} fi cd ${INSTALL_DIR} + if [ -d $INSTALL_DIR/gogs ]; then + rm -rf $INSTALL_DIR/gogs + fi GOGS_FILE=linux_${CURR_ARCH}.tar.gz if [ ! -f ${GOGS_FILE} ]; then wget ${GOGS_BIN} @@ -363,7 +369,7 @@ function install_gogs { exit 37836 else apt-get -y install unzip - unzip -A ${GOGS_FILE} + unzip ${GOGS_FILE} fi else tar -xzf ${INSTALL_DIR}/${GOGS_FILE}