forked from watson-developer-cloud/swift-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(docs): Alter documentation publishing to work on Jenkins
- Loading branch information
Anthony Oliveri
committed
Jan 5, 2019
1 parent
e754bfb
commit 160f23e
Showing
1 changed file
with
5 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,15 @@ | ||
#!/bin/bash | ||
|
||
# Generate API docs and upload them to Github on the gh-pages branch | ||
# IMPORTANT: This is only meant to be called from Travis builds! | ||
# IMPORTANT: This is only meant to be called from Jenkins! | ||
|
||
set -e | ||
|
||
# Configure Travis to be able to push to the Github repo | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "Travis CI" | ||
git config --replace-all remote.origin.fetch +refs/heads/*:refs/remotes/origin/* | ||
# Configure Jenkins to be able to push to the Github repo | ||
git config --global user.name "Jenkins" | ||
git remote rm origin | ||
git remote add origin https://watson-developer-cloud:${GH_TOKEN}@github.com/watson-developer-cloud/swift-sdk.git | ||
# git remote add origin https://watson-developer-cloud:${GH_TOKEN}@github.com/watson-developer-cloud/swift-sdk.git | ||
git remote add origin https://AnthonyOliveri:${GH_TOKEN}@github.com/watson-developer-cloud/swift-sdk.git | ||
git fetch | ||
git fetch --tags | ||
latestVersion=$(git describe --abbrev=0 --tags) | ||
|