Skip to content

Commit fc3be81

Browse files
committed
chore(*): fix remote auth
1 parent 690f595 commit fc3be81

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

.travis.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ cache:
1010

1111
git:
1212
depth: false
13+
14+
branches:
15+
only:
16+
- master
1317

1418
before_script:
1519
- bash ci/commit-lockfile.sh

ci/commit-lockfile.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,11 @@ if ! git diff-index --quiet HEAD --; then
88
git config --global user.email "$GITHUB_EMAIL"
99
git config --global user.name "Travis CI"
1010
git config --global push.default simple
11+
git remote add jenkins https://"$GITHUB_TOKEN"@github.com/"$TRAVIS_REPO_SLUG".git
1112

1213
git add package-lock.json
1314
git commit -m "chore(*): update lockfile"
1415
LAST_COMMIT=`git rev-parse HEAD`
15-
git remote
16-
git push origin $LAST_COMMIT:$TRAVIS_PULL_REQUEST_BRANCH
16+
git push jenkins $LAST_COMMIT:$TRAVIS_PULL_REQUEST_BRANCH
17+
git remote rm jenkins
1718
fi

0 commit comments

Comments
 (0)