Skip to content
Snippets Groups Projects
Commit 1f34ed82 authored by Xiao Gui's avatar Xiao Gui
Browse files

chore: add release to ci/cd

parent 68e0c5fd
No related branches found
No related tags found
No related merge requests found
......@@ -5,17 +5,32 @@ on:
- master
jobs:
release:
check-version:
outputs:
package-version: ${{ steps.set-version.outputs.package-version-from-json }}
runs-on: ubuntu-latest
steps:
- echo 'NYI'
# - name: Create Release
# id: create_release
# uses: actions/create-release@v1
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# with:
# tag_name: ${{ github.ref }}
# release_name: Release ${{ github.ref }}
# draft: false
# prerelease: false
\ No newline at end of file
- name: Checkout
uses: actions/checkout@v1
- name: Set version
id: set-version
run: |
PACKAGEJSON_VER=v$(cat package.json | jq -r '.version')
echo "::set-output name=package-version-from-json::$PACKAGEJSON_VER"
create-release:
needs: check-version
if: success()
runs-on: ubuntu-latest
steps:
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ needs.check-version.outputs.package-version }}
release_name: Release ${{ needs.check-version.outputs.package-version }}
draft: false
prerelease: false
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment