test checkout v2

This commit is contained in:
phips28 2020-04-03 12:31:23 +02:00
parent 118c20934f
commit 9933542c75
2 changed files with 3 additions and 3 deletions

View File

@ -3,7 +3,7 @@ name: "Bump Version"
on:
push:
branches:
- "master"
- "checkout_v2"
jobs:
bump-version:
@ -12,7 +12,7 @@ jobs:
steps:
- name: "Checkout source code"
uses: "actions/checkout@v1"
uses: "actions/checkout@v2"
with:
ref: ${{ github.ref }}
- name: "cat package.json"

View File

@ -36,7 +36,7 @@ Toolkit.run(async tools => {
await tools.runInWorkspace('git', ['config', 'user.email', '"gh-action-bump-version@users.noreply.github.com"'])
const currentBranch = /refs\/[a-zA-Z]+\/(.*)/.exec(process.env.GITHUB_REF)[1]
console.log('currentBranch:', currentBranch)
console.log('currentBranch:', currentBranch, process.env.GITHUB_REF)
// do it in the current checked out github branch (DETACHED HEAD)
// important for further usage of the package.json version