Skip to content

v3.1.3 (#107)

v3.1.3 (#107) #65

Workflow file for this run

name: Tag
on:
push:
branches:
- v2.x
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Create tag
run: |
tagName="v$(jq '.version' package.json | sed "s/\"//g")"
if [[ -n $(git ls-remote --tags origin $tagName) ]]; then
echo "tag $tagName already exists, skip release"
else
git config --local user.email "actions@github.com"
git config --local user.name "GitHub Actions"
git tag -a $tagName -m "release by Github Actions"
fi
- name: Push to repo
uses: ad-m/github-push-action@v0.6.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: master