Skip to content

Commit

Permalink
Revert to manual release.
Browse files Browse the repository at this point in the history
  • Loading branch information
jamalkm committed Apr 14, 2020
1 parent 4a86d5f commit 17734de
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 29 deletions.
19 changes: 7 additions & 12 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,23 @@ dist: trusty
sudo: required
language: bash

branches:
only:
- master

stages:
- name: Build and Release
if: tag IS present

jobs:
include:
- stage: "Build and Release"
name: "Build and release alfresco-keycloak-theme"
if: fork = false AND (branch = master) AND type != pull_request AND commit_message !~ /\[no-release\]/
before_deploy:
- ./set-version.sh
- source build.properties
- echo "Prepare deployment of alfresco-keycloak-theme-$THEME_VERSION"
- export TRAVIS_TAG=$THEME_VERSION
- git tag "$TRAVIS_TAG" -m ""
- echo "Prepare deployment of alfresco-keycloak-theme-$TRAVIS_TAG"
- ./build.sh
deploy:
provider: releases
api_key: $GITHUB_TOKEN
file: "alfresco-keycloak-theme-$THEME_VERSION.zip"
file: "alfresco-keycloak-theme-$TRAVIS_TAG.zip"
skip_cleanup: true
edge: true
edge: true
on:
tag: true
repo: Alfresco/alfresco-keycloak-theme
2 changes: 1 addition & 1 deletion build.properties
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1 +1 @@
THEME_VERSION=0.1
THEME_VERSION=0.2
22 changes: 22 additions & 0 deletions release.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/bash -e

set -o errexit

declare -r currentDir="$(dirname "${BASH_SOURCE[0]}")"
source "${currentDir}/build.properties"

CURRENT_BRANCH=$(git branch | grep '*' | cut -d' ' -f 2)

echo "Do you wish to tag and push the current branch '$CURRENT_BRANCH' as '$THEME_VERSION' ?"
select yn in "Yes" "No"; do
case $yn in
Yes)
git tag "$THEME_VERSION" -m ""
git push origin "$THEME_VERSION"
break
;;
No)
exit
;;
esac
done
16 changes: 0 additions & 16 deletions set-version.sh

This file was deleted.

0 comments on commit 17734de

Please sign in to comment.