n/a
Some checks failed
Build & Release / build-latest (push) Failing after 6s
Build & Release / version-release (push) Has been skipped

This commit is contained in:
Salastil
2025-11-16 15:24:42 -05:00
parent 7df50981ed
commit 19ca76d8c2

View File

@@ -4,36 +4,11 @@ on:
branches: ["master"]
tags:
- 'v*.*'
- 'latest'
jobs:
build-and-tag:
build-latest:
runs-on: ubuntu-latest
if: github.ref_type == 'branch'
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v4
with:
go-version: "1.22"
- name: Build
run: |
go mod tidy
go build -o Sneedchat-Discord-Bridge .
- name: Update Latest Tag
run: |
git config user.name "Gitea Actions"
git config user.email "actions@gitea.local"
git tag -f latest
git push -f origin latest
latest-release:
runs-on: ubuntu-latest
if: github.ref_type == 'tag' && github.ref_name == 'latest'
steps:
- name: Checkout
uses: actions/checkout@v4
@@ -47,11 +22,34 @@ jobs:
run: |
go mod tidy
go build -o Sneedchat-Discord-Bridge .
- name: Delete Previous Latest Release
continue-on-error: true
run: |
curl -X DELETE \
-H "Authorization: token ${{ secrets.CI_TOKEN }}" \
"https://git.salastil.com/api/v1/repos/Salastil/Sneedchat-Discord-Bridge-Go/releases/tags/latest"
- name: Delete Latest Tag
continue-on-error: true
run: |
git push origin :refs/tags/latest || true
- name: Create Latest Tag
run: |
git config user.name "Gitea Actions"
git config user.email "actions@gitea.local"
git tag latest
git push origin latest
- name: Create Latest Release
uses: actions/release-action@v1
with:
token: ${{ secrets.CI_TOKEN }}
tag_name: latest
name: Latest Build (Development)
body: "Automated build from master branch. This is a development build."
prerelease: true
files: Sneedchat-Discord-Bridge
version-release:
@@ -66,7 +64,7 @@ jobs:
with:
go-version: "1.22"
- name: Build Binaries
- name: Build Multi-Platform Binaries
run: |
mkdir -p dist
go mod tidy