YPSI-SAS / centctl

Centctl is a Go CLI which allows to manage multiple Centreon servers.
MIT License
11 stars 4 forks source link

Init Goreleaser for release management #19

Open juhnny5 opened 1 year ago

juhnny5 commented 1 year ago

Goreleaser is an automated deployment tool for Go projects. It can be used to automate the creation of binary packages for your Go project and the deployment of these packages on different platforms.

Here is an example of how to configure Goreleaser in a .goreleaser.yml file:

# Basic configuration
builds:
  - binary: centctl
    goos:
      - linux
      - darwin
      - windows
    goarch:
      - amd64

# Deployment configuration
deploy:
  # Deployment to GitHub Releases
  - provider: releases
    token:
      secure: <TOKEN> # Your GitHub authentication token
    file:
      - centctl_linux_amd64
      - centctl_darwin_amd64
      - centctl_windows_amd64.exe
    draft: false
    prerelease: false

# Release configuration
release:
  # Generate changelog from commits since last release
  changelog:
    generate: true
  # Use $GITHUB_TOKEN environment variable to authenticate requests
  github:
    api_key: $GITHUB_TOKEN