forked from googleapis/google-cloud-node
-
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.
docs: refactoring doc scripts (googleapis#1743)
- Loading branch information
1 parent
9194a6c
commit feb8b59
Showing
34 changed files
with
713 additions
and
517 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
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 |
---|---|---|
|
@@ -4,5 +4,5 @@ packages/*/CONTRIBUTORS | |
packages/*/COPYING | ||
**/node_modules | ||
**/coverage/* | ||
docs/json/**/*.json | ||
docs/json | ||
*.log |
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 |
---|---|---|
|
@@ -29,6 +29,7 @@ | |
"echo": true, | ||
"exit": true, | ||
"cd": true, | ||
"mkdir": true | ||
"mkdir": true, | ||
"test": true | ||
} | ||
} |
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 |
---|---|---|
|
@@ -21,7 +21,26 @@ before_script: | |
fi | ||
script: "node ./scripts/build.js" | ||
after_success: | ||
- if [ $IS_PUSH_TO_MASTER ]; then | ||
node ./scripts/build-docs.js; | ||
# We check to see if the job number ends with 1 (e.g. 234234.1) | ||
# letting us know it is the first pass for this build | ||
- if [ $IS_PUSH_TO_MASTER && "${TRAVIS_JOB_NUMBER}" == *1 ]; then | ||
rm -rf docs/json; | ||
npm run docs; | ||
git submodule add -q -b gh-pages https://${GH_OAUTH_TOKEN}@github.com/${GH_OWNER}/${GH_PROJECT_NAME} ghpages; | ||
cp -rf docs/json/* ghpages/json; | ||
cp docs/manifest.json ghpages; | ||
cd ghpages; | ||
set +e; | ||
git add .; | ||
set -e; | ||
if [[ -z "$(git status --porcelain)" ]]; then | ||
echo "Nothing to commit. Exiting without pushing changes."; | ||
exit 0; | ||
fi; | ||
git config user.name "travis-ci"; | ||
git config user.email "[email protected]"; | ||
git commit -m "Update docs for ${TRAVIS_TAG:-master} [ci skip]"; | ||
git status; | ||
git push -q https://${GH_OAUTH_TOKEN}@github.com/${GH_OWNER}/${GH_PROJECT_NAME} HEAD:gh-pages; | ||
fi | ||
sudo: false |
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
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
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
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.