Skip to content

Commit

Permalink
Create release.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Exarilo authored Aug 7, 2024
1 parent 8eb525e commit 9e05a76
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Publish Release

permissions:
contents: write

on:
push:
branches: [ main ]
paths:
- 'plugin.json'
workflow_dispatch:

jobs:
publish:

runs-on: windows-latest

steps:
- uses: actions/checkout@v3

- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0.x

- name: get version
id: version
uses: notiz-dev/github-action-json-property@release
with:
path: 'plugin.json'
prop_path: 'Version'

- run: echo ${{steps.version.outputs.prop}}

- name: Restore dependencies
run: dotnet restore

- name: Build
run: |
dotnet publish -c Release -r win-x64 --no-self-contained Flow.Launcher.Plugin.LinkOpener.csproj
7z a -tzip "Flow.Launcher.Plugin.LinkOpener.zip" "./bin/Release/win-x64/publish/*"
- name: Publish
uses: softprops/action-gh-release@v1
with:
files: "Flow.Launcher.Plugin.LinkOpener.zip"
tag_name: "v${{steps.version.outputs.prop}}"

0 comments on commit 9e05a76

Please sign in to comment.