Skip to content

Commit

Permalink
Improve logic of extracting BRANCH in CI (to account for cases wher…
Browse files Browse the repository at this point in the history
…e branch name includes a folder e.g. `issue/3112`)
  • Loading branch information
ryanio committed Apr 13, 2020
1 parent 516b32e commit 7297b53
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/e2e.npm.publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ npm-auth-to-token \

# Prep branch for Lerna's git-checks
if [[ $GITHUB_REF = 'refs/pull/'* ]]; then
BRANCH=${GITHUB_HEAD_REF##*/}
BRANCH=${GITHUB_HEAD_REF#refs/pull/}
else
BRANCH=${GITHUB_REF##*/}
BRANCH=${GITHUB_REF#refs/heads/}
fi

git checkout $BRANCH --
Expand Down

0 comments on commit 7297b53

Please sign in to comment.