Skip to content

Merge branch 'main' of https://github.com/mia-platform/mipy #4

Merge branch 'main' of https://github.com/mia-platform/mipy

Merge branch 'main' of https://github.com/mia-platform/mipy #4

Workflow file for this run

name: Release
on:
push:
branches:
- main # Esegue build snapshot per ogni push su main
tags:
- 'v*' # Esegue una release ufficiale quando il tag inizia con 'v'
env:
GORELEASER_VERSION: v2.3.2
jobs:
build:
name: Build and Release for Supported Architectures
runs-on: ubuntu-latest
steps:
# Checkout del codice
- name: Checkout Repository
uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0
with:
show-progress: false
# Setup di Go
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.23.2'
# Installazione di GoReleaser
- name: Install GoReleaser
uses: goreleaser/goreleaser-action@286f3b13b1b49da4ac219696163fb8c1c93e1200 # v6.0.0
with:

Check failure on line 34 in .github/workflows/release.yml

View workflow run for this annotation

GitHub Actions / Release

Invalid workflow file

The workflow is not valid. .github/workflows/release.yml (Line: 34, Col: 14): Unexpected value '' .github/workflows/release.yml (Line: 35, Col: 9): Unexpected value 'version'
version: ${{ env.GORELEASER_VERSION }}
install-only: true
# Esecuzione di GoReleaser per snapshot build (su main)
- name: Run GoReleaser (Snapshot)
if: github.ref == 'refs/heads/main'
run: goreleaser release --snapshot --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Esecuzione di GoReleaser per rilasci ufficiali (su tag)
- name: Run GoReleaser (Release)
if: startsWith(github.ref, 'refs/tags/v')
run: goreleaser release --clean --skip-validate --skip-publish=false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Salva i binari come artefatti in snapshot build
- name: Upload artifact (Snapshot)
if: github.ref == 'refs/heads/main'
uses: actions/upload-artifact@v3
with:
name: artifacts
path: bin/