@@ -5,6 +5,24 @@ branches:
5
5
except :
6
6
- /dev-build-.*/
7
7
8
+ before_script :
9
+ |
10
+ if [ ! -z "$TRAVIS_TAG" ]; then
11
+ echo -e "Incrementing version for release build...\n"
12
+ sed -i "/^version:/ s/.*/version : $TRAVIS_TAG/" $TRAVIS_BUILD_DIR/src/plugin.yml
13
+
14
+ git config --global user.email "[email protected] "
15
+ git config --global user.name "travis-ci"
16
+
17
+ git add -f $TRAVIS_BUILD_DIR/src/plugin.yml
18
+ git commit -m "Updated version for build release"
19
+ git push --quiet https://[email protected] /Codisimus/PhatLoots
20
+ else
21
+ echo -e "Appending build number to version for dev build...\n"
22
+ sed -i "/^version:/ s/.$/+$TRAVIS_BUILD_NUMBER/" $TRAVIS_BUILD_DIR/src/plugin.yml
23
+ cat $TRAVIS_BUILD_DIR/src/plugin.yml
24
+ fi
25
+
8
26
after_deploy :
9
27
|
10
28
if [ "$TRAVIS_BRANCH" == "master" ]; then
@@ -15,7 +33,7 @@ after_deploy:
15
33
cd $HOME
16
34
git config --global user.email "[email protected] "
17
35
git config --global user.name "travis-ci"
18
- git clone --quiet --branch=gh-pages https://${ AUTH_TOKEN} @github.com/Codisimus/PhatLoots gh-pages > /dev/null
36
+ git clone --quiet --branch=gh-pages https://[email protected] /Codisimus/PhatLoots gh-pages > /dev/null
19
37
20
38
cd gh-pages
21
39
git rm -rf ./javadoc
@@ -28,11 +46,18 @@ after_deploy:
28
46
fi
29
47
30
48
before_deploy :
31
- -
git config --global user.email "[email protected] "
32
- - git config --global user.name "Travis CI"
33
- - export GIT_TAG=dev-build-$TRAVIS_BUILD_NUMBER
34
- - git tag $GIT_TAG -a -m "Generated tag from TravisCI build $TRAVIS_BUILD_NUMBER on $(date -u "+%Y-%m-%d-%H-%M-%S")"
35
- -
git push --quiet https://[email protected] /Codisimus/PhatLoots $GIT_TAG
49
+ |
50
+ if [ -z "$TRAVIS_TAG" ]; then
51
+ echo -e "Creating tag for dev build...\n"
52
+
53
+ git config --global user.email "[email protected] "
54
+ git config --global user.name "travis-ci"
55
+ export GIT_TAG=dev-build-$TRAVIS_BUILD_NUMBER
56
+ git tag $GIT_TAG -a -m "Generated tag from TravisCI build $TRAVIS_BUILD_NUMBER on $(date -u "+%Y-%m-%d-%H-%M-%S")"
57
+ git push --quiet https://[email protected] /Codisimus/PhatLoots $GIT_TAG
58
+
59
+ echo -e "New tag $GIT_TAG \n"
60
+ fi
36
61
37
62
deploy :
38
63
- provider : releases
0 commit comments