You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by li...@apache.org on 2020/03/31 03:25:24 UTC
[servicecomb-java-chassis] branch master updated: [SCB-1835] travis
CI do not need release/deploy when cut release version
This is an automated email from the ASF dual-hosted git repository.
liubao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git
The following commit(s) were added to refs/heads/master by this push:
new 59a7dd5 [SCB-1835] travis CI do not need release/deploy when cut release version
59a7dd5 is described below
commit 59a7dd5cf32f328f0b00c2ac30ec462a1d24892b
Author: liubao <bi...@qq.com>
AuthorDate: Mon Mar 30 15:39:03 2020 +0800
[SCB-1835] travis CI do not need release/deploy when cut release version
---
.travis.yml | 4 +---
scripts/travis.sh | 65 ++++++++++++++-----------------------------------------
2 files changed, 17 insertions(+), 52 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index 3c4b500..6c5fdcd 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -12,6 +12,4 @@ jobs:
include:
- stage: Compilation and Installation
script: scripts/travis.sh install
- - stage: Deploy on
- script: if [ "$TRAVIS_PULL_REQUEST" == "false" ]; then bash scripts/travis.sh deploy;
- fi
+
diff --git a/scripts/travis.sh b/scripts/travis.sh
index 7bf3a58..302b995 100755
--- a/scripts/travis.sh
+++ b/scripts/travis.sh
@@ -17,58 +17,25 @@
## ---------------------------------------------------------------------------
#bin/sh
-##Check if the commit is tagged commit or not
-TAGGEDCOMMIT=$(git tag -l --contains HEAD)
-if [ "$TAGGEDCOMMIT" == "" ]; then
- TAGGEDCOMMIT=false
-else
- TAGGEDCOMMIT=true
-fi
-echo $TAGGEDCOMMIT
-
+## whenever commit to the repository, do Compilation and Installation
if [ "$1" == "install" ]; then
- if [ "$TAGGEDCOMMIT" == "true" ]; then
- echo "Skipping the installation as it is tagged commit"
- else
- mvn apache-rat:check -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -B -Pit,distribution
- if [ $? != 0 ]; then
- echo "${red}Rat check failed.${reset}"
- exit 1
- fi
-
- mvn clean install -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -B -Pdocker -Pdemo-run-release -Pjacoco -Pit -Pcoverage coveralls:report
- if [ $? == 0 ]; then
- echo "${green}Installation Success..${reset}"
- else
- echo "${red}Installation or Test Cases failed, please check the above logs for more details.${reset}"
- exit 1
- fi
+ mvn apache-rat:check -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -B -Pit,distribution
+ if [ $? != 0 ]; then
+ echo "${red}Rat check failed.${reset}"
+ exit 1
fi
- echo "Installation Completed"
-else
- if [ "$TAGGEDCOMMIT" == "true" ]; then
- echo "Decrypting the key"
- openssl aes-256-cbc -K $encrypted_6d31958a1ad0_key -iv $encrypted_6d31958a1ad0_iv -in gpg-sec.tar.enc -out gpg-sec.tar -d
- tar xvf gpg-sec.tar
- echo "Deploying Staging Release"
- mvn deploy -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -B -DskipTests -Prelease -Pdistribution -Ppassphrase --settings .travis.settings.xml
- if [ $? == 0 ]; then
- echo "${green}Staging Deployment is Success, please log on to Nexus Repo to see the staging release..${reset}"
- else
- echo "${red}Staging Release deployment failed.${reset}"
- exit 1
- fi
+
+ mvn clean install -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -B -Pdocker -Pdemo-run-release -Pjacoco -Pit -Pcoverage coveralls:report
+ if [ $? == 0 ]; then
+ echo "${green}Installation Success..${reset}"
else
- echo "Deploy a Non-Signed Staging Release"
- mvn deploy -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -B -DskipTests --settings .travis.settings.xml
- if [ $? == 0 ]; then
- echo "${green}Snapshot Deployment is Success, please log on to Nexus Repo to see the snapshot release..${reset}"
- else
- echo "${red}Snapshot deployment failed.${reset}"
- # No need to exit 1 here as the snapshot depoyment will fail for private builds as decryption of password is allowed for ServiceComb repo and not forked repo's.
- fi
-
+ echo "${red}Installation or Test Cases failed, please check the above logs for more details.${reset}"
+ exit 1
fi
- echo "Deployment Completed"
+
+ echo "Compilation and Installation Completed"
+else
+ echo "Not Implemented parameter"
+ exit 1
fi