-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (48 loc) · 1.47 KB
/
dev-build.yaml
File metadata and controls
57 lines (48 loc) · 1.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
name: Development Build
on:
push:
branches:
- staging
paths-ignore:
- '**.md'
- 'docs/**'
workflow_dispatch: # Allows manual triggering
permissions:
contents: write
jobs:
dev-build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.23'
check-latest: true
- name: Run GoReleaser Snapshot
uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser
version: latest
args: release --snapshot --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CGO_ENABLED: 0 # Disable CGO for better cross-compilation compatibility
- name: Set date
id: date
run: echo "DATE=$(date +'%Y%m%d%H%M')" >> $GITHUB_OUTPUT
- name: Create/Update Development Release
uses: softprops/action-gh-release@v1
with:
name: Development Build
tag_name: v0.0.0-dev.${{ steps.date.outputs.DATE }}
files: dist/*
prerelease: true
body: |
# Development Build
This is an automated development build from commit ${{ github.sha }}
This build is for testing purposes only and will be overwritten with each push to the main branch.
generate_release_notes: false