This commit is contained in:
parent
a5c7a5fea7
commit
048b9b8547
2 changed files with 24 additions and 17 deletions
|
@ -2,14 +2,12 @@
|
|||
name: Build and release
|
||||
|
||||
on:
|
||||
release:
|
||||
types: [published]
|
||||
# workflow_dispatch:
|
||||
# inputs:
|
||||
# version:
|
||||
# description: 'Version'
|
||||
# required: true
|
||||
# default: 'v0'
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
version:
|
||||
description: 'Version'
|
||||
required: true
|
||||
default: 'v0'
|
||||
|
||||
jobs:
|
||||
test:
|
||||
|
@ -36,12 +34,20 @@ jobs:
|
|||
run: |
|
||||
task build VERSION=${{ github.ref_name }}
|
||||
|
||||
- name: Upload Release Asset
|
||||
uses: actions/upload-release-asset@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
# - name: Upload Release Asset
|
||||
# uses: actions/upload-release-asset@v1
|
||||
# env:
|
||||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
# with:
|
||||
# upload_url: ${{ github.event.release.upload_url }}
|
||||
# asset_path: ./lobby2-${{ github.ref_name }}-amd64
|
||||
# asset_name: lobby2-${{ github.ref_name }}-amd64
|
||||
# asset_content_type: application/octet-stream
|
||||
|
||||
- uses: actions/forgejo-release@v2
|
||||
with:
|
||||
upload_url: ${{ github.event.release.upload_url }}
|
||||
asset_path: ./lobby2-${{ github.ref_name }}-amd64
|
||||
asset_name: lobby2-${{ github.ref_name }}-amd64
|
||||
asset_content_type: application/octet-stream
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
direction: upload
|
||||
url: https://gitea.ceperka.net
|
||||
release-dir: bin/
|
||||
release-notes-assistant: true
|
||||
|
|
|
@ -18,4 +18,5 @@ tasks:
|
|||
build:
|
||||
cmds:
|
||||
- go mod tidy
|
||||
- go build -o lobby2-{{ .VERSION }}-amd64 cli/*.go
|
||||
- mkdir -p bin
|
||||
- go build -o bin/lobby2-{{ .VERSION }}-amd64 cli/*.go
|
||||
|
|
Loading…
Reference in a new issue