Merge pull request #59 from mubaidr/contributors-readme-action-SAXQx5… #31
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: release | |
'on': | |
push: | |
branches: | |
- master | |
concurrency: | |
group: release-${{ github.ref }} | |
cancel-in-progress: true | |
defaults: | |
run: | |
shell: 'bash' | |
jobs: | |
draft_release: | |
permissions: | |
contents: write # Allows this job to create releases | |
strategy: | |
fail-fast: true | |
matrix: | |
# os: [macos-latest, ubuntu-latest, windows-latest] | |
os: [ubuntu-latest] | |
runs-on: ${{ matrix.os }} | |
timeout-minutes: 5 | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
# cache: 'npm' | |
- run: npm i | |
env: | |
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1 | |
- name: Get Package Version | |
id: get-version | |
run: echo "::set-output name=version::$(node -p "require('./package.json').version")" | |
- run: npm run build | |
- run: zip -r ${{ steps.get-version.outputs.version }}.zip dist | |
- name: GH Release | |
uses: softprops/action-gh-release@v0.1.15 | |
with: | |
tag_name: ${{ steps.get-version.outputs.version }} | |
release_name: ${{ steps.get-version.outputs.version }} | |
draft: true | |
files: ${{ steps.get-version.outputs.version }}.zip |