Fix: add permissions, simplify release

This commit is contained in:
ThisIsDara
2026-05-04 08:05:20 +03:30
parent 9019c96a55
commit 70575aa5a5
+4 -9
View File
@@ -4,16 +4,12 @@ on:
push:
tags:
- 'v*'
workflow_dispatch:
inputs:
release:
description: 'Create release'
required: false
default: 'true'
jobs:
build:
runs-on: windows-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
@@ -31,17 +27,16 @@ jobs:
name: mhr-cfw-go
path: mhr-cfw-go.exe
- name: Download for release
- name: Download artifact
uses: actions/download-artifact@v4
with:
name: mhr-cfw-go
path: .
- name: Release
if: github.event_name == 'workflow_dispatch' || startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v2
with:
files: mhr-cfw-go.exe
generate_release_notes: true
body: "Built from commit ${{ github.sha }}"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}