Skip to content

Fix workflow

Fix workflow #10

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
jobs:
zip-release:
runs-on: ubuntu-latest
env:
SOURCE_SUBDIRECTORY: app
RELEASE_ZIP_FILENAME: shadertoy-unofficial-plugin
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Install zip and jq
run: sudo apt-get install zip jq
- name: Get version from manifest.json
id: version
run: echo "::set-output name=version::$(jq -r .version app/manifest.json)"
- name: Zip subdirectory
run: >
cd ${{ env.SOURCE_SUBDIRECTORY }} &&
zip -r ${{ env.RELEASE_ZIP_FILENAME }}-${{ steps.version.outputs.version }}.zip ./
- 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
- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./${{ env.RELEASE_ZIP_FILENAME }}-${{ steps.version.outputs.version }}.zip
asset_name: ${{ env.RELEASE_ZIP_FILENAME }}-${{ steps.version.outputs.version }}.zip
asset_content_type: application/zip