Browse Source

test with credentials

main
Distopico Vegan 6 years ago
parent
commit
828db08ffd
1 changed files with 10 additions and 9 deletions
  1. +10
    -9
      .gitlab-ci.yml

+ 10
- 9
.gitlab-ci.yml View File

@ -68,7 +68,8 @@ testRelease:
only:
- master
script:
- ./gradlew --console=plain testReleaseUnitTest
- echo ""
#- ./gradlew --console=plain testReleaseUnitTest
buildDebug:
stage: build
@ -101,12 +102,12 @@ release:
- wget --quiet --output-document=/tmp/nvm-install.sh https://raw.githubusercontent.com/creationix/nvm/v0.33.6/install.sh
- bash /tmp/nvm-install.sh
- export NVM_DIR="$HOME/.nvm" &&. "$NVM_DIR/nvm.sh" && nvm install 8
- eval $(ssh-agent -s)
#- eval $(ssh-agent -s)
#- echo "$GIT_SSH_KEY" | tr -d '\r' | ssh-add - > /dev/null
- ssh-add <(echo "$GIT_SSH_KEY")
- mkdir -p ~/.ssh && ssh-keyscan $GITLAB_URL >> ~/.ssh/known_hosts
- git config --global user.email $GIT_AUTHOR_EMAIL
- git config --global user.name $GIT_AUTHOR_NAME
#- ssh-add <(echo "$GIT_SSH_KEY")
#- mkdir -p ~/.ssh && ssh-keyscan $GITLAB_URL >> ~/.ssh/known_hosts
#- git config --global user.email $GIT_AUTHOR_EMAIL
#- git config --global user.name $GIT_AUTHOR_NAME
cache: {}
script:
- npm install -g semantic-release @semantic-release/commit-analyzer @semantic-release/release-notes-generator @semantic-release/changelog @semantic-release/exec @semantic-release/git @semantic-release/gitlab
@ -115,6 +116,6 @@ release:
- echo $CI_REPOSITORY_URL
- echo $CI_PROJECT_PATH
- echo $CI_PROJECT_PATH_SLUG
- git checkout develop && git rebase master
- git push git@${GITLAB_URL}:${CI_PROJECT_PATH}.git develop
#- git push https://${GIT_USERNAME}:${GIT_ACCESS_TOKEN}@${GITLAB_URL}/${CI_PROJECT_PATH_SLUG}.git develop
- git checkout -b develop origin/develop && git rebase master
#- git push git@${GITLAB_URL}:${CI_PROJECT_PATH}.git develop
- git push https://${GIT_CREDENTIALS}@${GITLAB_URL}/${CI_PROJECT_PATH}.git develop

Loading…
Cancel
Save