Skip to content

Commit 9aa0056

Browse files
committed
restore helm chart repo index in separate stage
1 parent da57d70 commit 9aa0056

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

.travis.yml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
stages:
2+
- restore-helm-repo-index
23
- unittest
34
- exampletest
45
- name: dockerbuild
56
if: branch = master
67
- name: website
78
if: branch = master AND type != pull_request
9+
- name: restore-helm-repo-index
10+
if: branch = master AND type != pull_request
811
- name: sourcedocs
912
if: branch = master AND type != pull_request
1013

@@ -55,7 +58,19 @@ jobs:
5558
- git config --global user.email "${GH_EMAIL}"
5659
- echo "machine github.com login ${GH_NAME} password ${GH_TOKEN}" > ~/.netrc
5760
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
58-
- tempdir=$(mktemp -d) && mkdir -p $tempdir && cd $tempdir && git clone --single-branch --branch gh-pages [email protected]:Accenture/reactive-interaction-gateway.git && cd reactive-interaction-gateway && git checkout $(git rev-list -n1 HEAD -- index.yaml)~1 -- index.yaml && git add index.yaml && git commit -m "Auto-restore Helm chart repo index after Docusaurus publish" && git push --verbose
61+
- stage: restore-helm-repo-index
62+
language: minimal
63+
script:
64+
- git config --global user.name "${GH_NAME}"
65+
- git config --global user.email "${GH_EMAIL}"
66+
- git fetch --unshallow
67+
- git config remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*"
68+
- git fetch origin
69+
- git checkout gh-pages
70+
- git checkout $(git rev-list -n1 HEAD -- index.yaml)~1 -- index.yaml
71+
- git add index.yaml
72+
- git commit -m "Auto-restore Helm chart repo index after Docusaurus publish"
73+
- git push
5974
- stage: sourcedocs
6075
<<: *elixir-env
6176
script:

foo

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
foo

0 commit comments

Comments
 (0)