From 097c456a3b4f8f522a9d168bfb4f6a5d2661e659 Mon Sep 17 00:00:00 2001 From: Carlos A Becker Date: Mon, 21 Jun 2021 02:26:17 +0000 Subject: [PATCH] chore(ci): publish to fury Signed-off-by: Carlos A Becker --- .github/workflows/build.yml | 1 + .goreleaser.yml | 8 ++++++++ scripts/fury-upload.sh | 6 ++++++ 3 files changed, 15 insertions(+) create mode 100755 scripts/fury-upload.sh diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3f532e64d..8016c16e0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -94,6 +94,7 @@ jobs: TWITTER_CONSUMER_SECRET: ${{ secrets.TWITTER_CONSUMER_SECRET }} TWITTER_ACCESS_TOKEN: ${{ secrets.TWITTER_ACCESS_TOKEN }} TWITTER_ACCESS_TOKEN_SECRET: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }} + FURY_TOKEN: ${{ secrets.FURY_TOKEN }} run: | if [[ $GITHUB_REF == refs/tags/v* ]]; then ./goreleaser diff --git a/.goreleaser.yml b/.goreleaser.yml index d45c704c9..af231775d 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -126,6 +126,7 @@ scoop: license: MIT nfpms: - file_name_template: '{{ .ProjectName }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}' + id: packages homepage: https://goreleaser.com description: Deliver Go binaries as fast and easily as possible maintainer: Carlos Alexandro Becker @@ -156,6 +157,13 @@ snapcrafts: grade: stable confinement: classic publish: true + +publishers: + - name: fury.io + ids: + - packages + cmd: ./scripts/fury-upload.sh {{ .ArtifactName }} + release: discussion_category_name: Announcements footer: | diff --git a/scripts/fury-upload.sh b/scripts/fury-upload.sh new file mode 100755 index 000000000..6aaadc42d --- /dev/null +++ b/scripts/fury-upload.sh @@ -0,0 +1,6 @@ +#!/bin/bash +set -e +if [ "${1: -4}" == ".deb" ] || [ "${1: -4}" == ".rpm" ]; then + cd dist + curl -F package="@$1" "https://$FURY_TOKEN@push.fury.io/goreleaser/" +fi