From bac501329ed3d754d9d0f1c100599d3e900dd359 Mon Sep 17 00:00:00 2001 From: Rongfeng Fu Date: Tue, 4 Jan 2022 11:47:03 +0800 Subject: [PATCH] reset version && build.sh fix (#78) --- rpm/build.sh | 8 ++++---- rpm/ob-deploy.spec | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/rpm/build.sh b/rpm/build.sh index 564b9d8..96a0e0e 100755 --- a/rpm/build.sh +++ b/rpm/build.sh @@ -104,7 +104,7 @@ function build() cd2workdir DIR=`pwd` cd .. - VERSION=`grep 'Version:' ob-deploy.spec | head -n1 | awk -F' ' '{print $2}'` + VERSION=`grep 'Version:' rpm/ob-deploy.spec | head -n1 | awk -F' ' '{print $2}'` CID=`git log |head -n1 | awk -F' ' '{print $2}'` BRANCH=`git branch | grep -e "^\*" | awk -F' ' '{print $2}'` DATE=`date '+%b %d %Y %H:%M:%S'` @@ -115,9 +115,9 @@ function build() mkdir -p $BUILD_DIR/mirror/remote wget https://mirrors.aliyun.com/oceanbase/OceanBase.repo -O $BUILD_DIR/mirror/remote/OceanBase.repo cat _cmd.py | sed "s//$CID/" | sed "s//$BRANCH/" | sed "s//$DATE/" | sed "s//$OBD_DUBUG/" | sed "s//$VERSION/" > obd.py - pip install -r $req_fn.txt | exit 1 - pip install -r plugins-$req_fn.txt --target=$BUILD_DIR/lib/site-packages | exit 1 - pyinstaller --hidden-import=decimal --hidden-import=configparser -F obd.py | exit 1 + pip install -r $req_fn.txt || exit 1 + pip install -r plugins-$req_fn.txt --target=$BUILD_DIR/lib/site-packages || exit 1 + pyinstaller --hidden-import=decimal --hidden-import=configparser -F obd.py || exit 1 rm -f obd.py obd.spec cp -r plugins $BUILD_DIR/plugins rm -fr /usr/obd /usr/bin/obd diff --git a/rpm/ob-deploy.spec b/rpm/ob-deploy.spec index e5d877f..5e08e82 100644 --- a/rpm/ob-deploy.spec +++ b/rpm/ob-deploy.spec @@ -1,5 +1,5 @@ Name: ob-deploy -Version: 1.2.1 +Version: 1.2.0 Release: %(echo $RELEASE)%{?dist} # if you want use the parameter of rpm_create on build time, # uncomment below -- GitLab