image: jjsoft2018/gitlab-runner-os:latest stages: - test_coverage # - version - publish cache: paths: - node_modules/ - yarn.lock before_script: - echo "//registry.npmjs.org/:_authToken=$NPM_AUTH_TOKEN" > ~/.npmrc - yarn install test: stage: test_coverage script: - yarn coverage #version: # stage: version # only: # - develop # script: # - git config --global user.email "$GITLAB_USER_EMAIL" # - git config --global user.name "$GITLAB_USER_NAME" # - git remote set-url --push origin "https://gitlab-ci-token:${CI_JOB_TOKEN}@gitlab.jjsoft.kr/bckim/graphql-harmony.git" # - git tag -a v0.0.6 -m "version 0.0.6" # - git tag # - git push origin --tags #version: # stage: version # only: # - develop # script: # - git remote -v # - bash version.sh #version: # stage: version # only: # - develop # script: # - mkdir ~/.ssh # - echo $GITLAB_PRIVATE_KEY > ~/.ssh/id_rsa # - chmod 400 ~/.ssh/id_rsa # - echo $GITLAB_PUBLIC_KEY > ~/.ssh/known_hosts # - git config --global user.email "$GITLAB_USER_EMAIL" # - git config --global user.name "$GITLAB_USER_NAME" # - git remote -v # - git remote remove origin # - git remote add origin ../../bckim/graphql-harmony.git # - git remote -v # - git checkout master # - git reset --hard origin/master # - git merge $CI_BUILD_REF # - git push origin master # - git tag -a v0.0.1 -m 'version 0.0.1' # - git tag # - git push origin --tags publish: stage: publish only: - tags script: - yarn build - npm publish