Skip to content

Commit

Permalink
test on windows
Browse files Browse the repository at this point in the history
Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
  • Loading branch information
caarlos0 committed Sep 16, 2023
1 parent 75c6677 commit 50e1f71
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 82 deletions.
60 changes: 9 additions & 51 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,9 @@
name: release

# on:
# push:
# tags: ['v*']
#
# jobs:
# goreleaser:
# uses: charmbracelet/meta/.github/workflows/goreleaser.yml@main
# secrets:
# docker_username: caarlos0
# docker_token: ${{ secrets.DOCKER_PASSWORD }}
# gh_pat: ${{ secrets.GH_PAT }}
# goreleaser_key: ${{ secrets.GORELEASER_KEY }}
#

on:
workflow_dispatch:
inputs:
tag:
description: 'New tag name'
required: true
push:
tags:
- v.*

permissions:
contents: write
Expand All @@ -28,43 +12,17 @@ permissions:

jobs:
goreleaser:
runs-on: ubuntu-latest
# env:
# DOCKER_CLI_EXPERIMENTAL: "enabled"
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- run: git tag ${{ github.event.inputs.tag }}
# - uses: docker/setup-qemu-action@v1
# - uses: docker/setup-buildx-action@v1
- uses: actions/setup-go@v3
- uses: actions/setup-go@v4
with:
go-version: '1.19'
# cache: true
# - name: dockerhub-login
# uses: docker/login-action@49ed152c8eca782a232dede0303416e8f356c37b # v1
# with:
# username: ${{ secrets.DOCKER_USERNAME }}
# password: ${{ secrets.DOCKER_PASSWORD }}
# - name: ghcr-login
# uses: docker/login-action@49ed152c8eca782a232dede0303416e8f356c37b # v1
# with:
# registry: ghcr.io
# username: ${{ github.repository_owner }}
# password: ${{ secrets.GITHUB_TOKEN }}
# - run: |
# curl -sfL https://goreleaser.com/static/run >/tmp/goreleaser
# chmod +x /tmp/goreleaser
# - run: /tmp/goreleaser release --rm-dist
# env:
# VERSION: nightly
# DISTRIBUTION: pro
#
- uses: goreleaser/goreleaser-action@v3
go-version: "stable"
- uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser-pro
version: latest
args: release --clean --verbose -f .goreleaser.4.yml
env:
GITHUB_TOKEN: ${{ secrets.GH_PAT }}
GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }}

44 changes: 13 additions & 31 deletions .goreleaser.4.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# yaml-language-server: $schema=https://goreleaser.com/static/schema.json
# This is an example goreleaser.yaml file with some sane defaults.
# Make sure to check the documentation at http://goreleaser.com
builds:
Expand All @@ -7,35 +8,16 @@ builds:
- CGO_ENABLED=0
main: ./main.go
goos:
- darwin
- linux
- windows
goarch:
- amd64
checksum:
name_template: "checksums.txt"
snapshot:
name_template: "{{ .Tag }}-next"
changelog:
sort: asc
filters:
exclude:
- "^docs:"
- "^test:"
brews:
- tap:
owner: caarlos0
name: test
folder: Formula
caveats: "Test formula, dont use it. It doesnt do anything"
- tap:
owner: caarlos0
name: test
folder: Formula
caveats: "Test formula, dont use it. It doesnt do anything, versioned"
name: "{{.ProjectName}}@{{.Tag}}"
scoop:
name: foobar
bucket:
owner: caarlos0
name: test

chocolateys:
- name: foo
owners: carlos
title: lalal
authors: carlos
api_key: fake
copyright: mit
license_url: https://foo.com/mit
summary: aaaa
description: aaaaaa
project_url: https://foo.com

0 comments on commit 50e1f71

Please sign in to comment.