Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

updated goreleaser configuration #790

Merged
merged 1 commit into from Oct 7, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
23 changes: 9 additions & 14 deletions .github/workflows/release.yml
Expand Up @@ -8,22 +8,17 @@ jobs:
release:
name: Release
runs-on: ubuntu-latest
permissions:
contents: write
packages: write
issues: write
steps:
- name: Checkout Code
uses: actions/checkout@v3

- name: Set up Go 1.17
uses: actions/setup-go@v3
- uses: actions/checkout@v3
with:
go-version: 1.17

- name: Fetch tags
run: git fetch --depth=1 origin +refs/tags/*:refs/tags/*

- name: setup release environment
fetch-depth: 0
- name: setup environment
run: |-
echo 'GITHUB_TOKEN=${{secrets.GORELEASER_TOKEN }}' > .release-env

- name: release publish
echo 'GITHUB_TOKEN=${{secrets.GORELEASER_PAT }}' > .release-env
- name: run goreleaser
run: make release

8 changes: 3 additions & 5 deletions .goreleaser.yml
Expand Up @@ -85,8 +85,7 @@ builds:
- amd64

archives:
-
format_overrides:
- format_overrides:
- goos: windows
format: zip

Expand All @@ -104,11 +103,10 @@ changelog:
- '^test:'

brews:
-
name: 'pop'
- name: 'pop'
tap:
owner: gobuffalo
name: homebrew-tap
homepage: "https://gobuffalo.io/docs/db/getting-started"
homepage: "https://gobuffalo.io/documentation/database/pop/"
description: "A Tasty Treat For All Your Database Needs"
skip_upload: "auto"
12 changes: 1 addition & 11 deletions Makefile
@@ -1,5 +1,5 @@
PACKAGE_NAME := github.com/gobuffalo/pop
GOLANG_CROSS_VERSION ?= v1.17.6
GOLANG_CROSS_VERSION ?= v1.18

TAGS ?= "sqlite"
GO_BIN ?= go
Expand All @@ -19,14 +19,6 @@ lint:
release-test:
./test.sh

.PHONY: sysroot-pack
sysroot-pack:
@tar cf - $(SYSROOT_DIR) -P | pv -s $[$(du -sk $(SYSROOT_DIR) | awk '{print $1}') * 1024] | pbzip2 > $(SYSROOT_ARCHIVE)

.PHONY: sysroot-unpack
sysroot-unpack:
@pv $(SYSROOT_ARCHIVE) | pbzip2 -cd | tar -xf -

.PHONY: release-dry-run
release-dry-run:
@docker run \
Expand All @@ -36,7 +28,6 @@ release-dry-run:
--env-file .release-env \
-v /var/run/docker.sock:/var/run/docker.sock \
-v `pwd`:/go/src/$(PACKAGE_NAME) \
-v `pwd`/sysroot:/sysroot \
-w /go/src/$(PACKAGE_NAME) \
goreleaser/goreleaser-cross:${GOLANG_CROSS_VERSION} \
--rm-dist --skip-validate --skip-publish --snapshot
Expand All @@ -54,7 +45,6 @@ release:
--env-file .release-env \
-v /var/run/docker.sock:/var/run/docker.sock \
-v `pwd`:/go/src/$(PACKAGE_NAME) \
-v `pwd`/sysroot:/sysroot \
-w /go/src/$(PACKAGE_NAME) \
goreleaser/goreleaser-cross:${GOLANG_CROSS_VERSION} \
release --rm-dist