Switched back to release and CI workflows
This commit is contained in:
parent
55791627a6
commit
b95c3eb040
|
|
@ -37,62 +37,3 @@ jobs:
|
||||||
env:
|
env:
|
||||||
TEST_DYNAMO_URL: "http://localstack:4566"
|
TEST_DYNAMO_URL: "http://localstack:4566"
|
||||||
GOPRIVATE: "github:com/lmika/*"
|
GOPRIVATE: "github:com/lmika/*"
|
||||||
|
|
||||||
# Start Release
|
|
||||||
Site:
|
|
||||||
runs-on: docker
|
|
||||||
env:
|
|
||||||
NETLIFY_SITE_ID: 987651c8-4ffd-48d8-af67-4dbd49c48887
|
|
||||||
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
- name: Setup Go
|
|
||||||
uses: actions/setup-go@v3
|
|
||||||
with:
|
|
||||||
go-version: 1.24
|
|
||||||
- uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: 21.1
|
|
||||||
- name: Install Hugo
|
|
||||||
run: |
|
|
||||||
curl -LO https://github.com/gohugoio/hugo/releases/download/v0.146.0/hugo_extended_0.146.0_linux-amd64.deb
|
|
||||||
apt install -y ./hugo_extended_0.146.0_linux-amd64.deb
|
|
||||||
- name: Install Netlify CLI
|
|
||||||
run: |
|
|
||||||
npm install netlify-cli@15.0.1 -g
|
|
||||||
- name: Build Site
|
|
||||||
run: |
|
|
||||||
cd _site
|
|
||||||
mkdir -p themes
|
|
||||||
git clone https://github.com/alex-shpak/hugo-book.git themes/hugo-book
|
|
||||||
npm install
|
|
||||||
hugo --minify
|
|
||||||
- name: Publish Site
|
|
||||||
run: |
|
|
||||||
cd _site
|
|
||||||
netlify deploy --dir docs --prod
|
|
||||||
|
|
||||||
'Release MacOS':
|
|
||||||
# needs: build
|
|
||||||
runs-on: macos
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
- name: Setup Go
|
|
||||||
uses: actions/setup-go@v3
|
|
||||||
with:
|
|
||||||
go-version: 1.25
|
|
||||||
- name: Configure
|
|
||||||
run: |
|
|
||||||
git config --global url."https://${{ secrets.GO_MODULES_TOKEN }}:x-oauth-basic@github.com/lmika".insteadOf "https://github.com/lmika"
|
|
||||||
- name: Setup Goreleaser
|
|
||||||
run: |
|
|
||||||
go install github.com/goreleaser/goreleaser/v2@v2.12.7
|
|
||||||
- name: Release
|
|
||||||
# if: startsWith(github.ref, 'refs/tags/')
|
|
||||||
run: |
|
|
||||||
goreleaser release -f macos.goreleaser.yml --skip=validate --clean --snapshot
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
HOMEBREW_TAP_PRIVATE_KEY: ${{ secrets.HOMEBREW_TAP_PRIVATE_KEY }}
|
|
||||||
|
|
@ -1,11 +1,12 @@
|
||||||
name: release
|
name: Release
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
tags:
|
tags:
|
||||||
- 'v*'
|
- 'v*'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
Build:
|
||||||
runs-on: docker
|
runs-on: docker
|
||||||
services:
|
services:
|
||||||
localstack:
|
localstack:
|
||||||
|
|
@ -20,7 +21,7 @@ jobs:
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@v3
|
uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: 1.24
|
go-version: 1.25
|
||||||
- name: Configure
|
- name: Configure
|
||||||
run: |
|
run: |
|
||||||
git config --global url."https://${{ secrets.GO_MODULES_TOKEN }}:x-oauth-basic@github.com/lmika".insteadOf "https://github.com/lmika"
|
git config --global url."https://${{ secrets.GO_MODULES_TOKEN }}:x-oauth-basic@github.com/lmika".insteadOf "https://github.com/lmika"
|
||||||
|
|
@ -30,53 +31,86 @@ jobs:
|
||||||
go get ./...
|
go get ./...
|
||||||
go test -p 1 ./...
|
go test -p 1 ./...
|
||||||
env:
|
env:
|
||||||
GOPRIVATE: "github:com/lmika/*"
|
|
||||||
TEST_DYNAMO_URL: "http://localstack:4566"
|
TEST_DYNAMO_URL: "http://localstack:4566"
|
||||||
|
GOPRIVATE: "github:com/lmika/*"
|
||||||
|
|
||||||
release-macos:
|
Site:
|
||||||
needs: build
|
needs: Build
|
||||||
runs-on: macos-12
|
runs-on: docker
|
||||||
|
env:
|
||||||
|
NETLIFY_SITE_ID: 987651c8-4ffd-48d8-af67-4dbd49c48887
|
||||||
|
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@v3
|
uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: 1.22
|
go-version: 1.24
|
||||||
|
- uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: 21.1
|
||||||
|
- name: Install Hugo
|
||||||
|
run: |
|
||||||
|
curl -LO https://github.com/gohugoio/hugo/releases/download/v0.146.0/hugo_extended_0.146.0_linux-amd64.deb
|
||||||
|
apt install -y ./hugo_extended_0.146.0_linux-amd64.deb
|
||||||
|
- name: Install Netlify CLI
|
||||||
|
run: |
|
||||||
|
npm install netlify-cli@15.0.1 -g
|
||||||
|
- name: Build Site
|
||||||
|
run: |
|
||||||
|
cd _site
|
||||||
|
mkdir -p themes
|
||||||
|
git clone https://github.com/alex-shpak/hugo-book.git themes/hugo-book
|
||||||
|
npm install
|
||||||
|
hugo --minify
|
||||||
|
- name: Publish Site
|
||||||
|
run: |
|
||||||
|
cd _site
|
||||||
|
netlify deploy --dir docs --prod
|
||||||
|
|
||||||
|
'Release MacOS':
|
||||||
|
needs: Build
|
||||||
|
runs-on: macos
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: Setup Go
|
||||||
|
uses: actions/setup-go@v3
|
||||||
|
with:
|
||||||
|
go-version: 1.25
|
||||||
- name: Configure
|
- name: Configure
|
||||||
run: |
|
run: |
|
||||||
git config --global url."https://${{ secrets.GO_MODULES_TOKEN }}:x-oauth-basic@github.com/lmika".insteadOf "https://github.com/lmika"
|
git config --global url."https://${{ secrets.GO_MODULES_TOKEN }}:x-oauth-basic@github.com/lmika".insteadOf "https://github.com/lmika"
|
||||||
- name: Setup Goreleaser
|
- name: Setup Goreleaser
|
||||||
run: |
|
run: |
|
||||||
brew install goreleaser/tap/goreleaser
|
go install github.com/goreleaser/goreleaser/v2@v2.12.7
|
||||||
brew install goreleaser
|
|
||||||
- name: Release
|
- name: Release
|
||||||
if: startsWith(github.ref, 'refs/tags/')
|
|
||||||
run: |
|
run: |
|
||||||
goreleaser release -f macos.goreleaser.yml --skip=validate --clean
|
goreleaser publish -f macos.goreleaser.yml --skip=validate --clean
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
HOMEBREW_GITHUB_TOKEN: ${{ secrets.HOMEBREW_GITHUB_TOKEN }}
|
HOMEBREW_TAP_PRIVATE_KEY: ${{ secrets.HOMEBREW_TAP_PRIVATE_KEY }}
|
||||||
|
|
||||||
release-linux:
|
# release-linux:
|
||||||
needs: build
|
# needs: build
|
||||||
runs-on: ubuntu-latest
|
# runs-on: ubuntu-latest
|
||||||
steps:
|
# steps:
|
||||||
- name: Checkout
|
# - name: Checkout
|
||||||
uses: actions/checkout@v2
|
# uses: actions/checkout@v2
|
||||||
- name: Setup Go
|
# - name: Setup Go
|
||||||
uses: actions/setup-go@v3
|
# uses: actions/setup-go@v3
|
||||||
with:
|
# with:
|
||||||
go-version: 1.22
|
# go-version: 1.22
|
||||||
- name: Configure
|
# - name: Configure
|
||||||
run: |
|
# run: |
|
||||||
git config --global url."https://${{ secrets.GO_MODULES_TOKEN }}:x-oauth-basic@github.com/lmika".insteadOf "https://github.com/lmika"
|
# git config --global url."https://${{ secrets.GO_MODULES_TOKEN }}:x-oauth-basic@github.com/lmika".insteadOf "https://github.com/lmika"
|
||||||
- name: Release
|
# - name: Release
|
||||||
uses: goreleaser/goreleaser-action@v1
|
# uses: goreleaser/goreleaser-action@v1
|
||||||
if: startsWith(github.ref, 'refs/tags/')
|
# if: startsWith(github.ref, 'refs/tags/')
|
||||||
with:
|
# with:
|
||||||
version: latest
|
# version: latest
|
||||||
args: release -f linux.goreleaser.yml --skip=validate --clean
|
# args: release -f linux.goreleaser.yml --skip=validate --clean
|
||||||
env:
|
# env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
HOMEBREW_GITHUB_TOKEN: ${{ secrets.HOMEBREW_GITHUB_TOKEN }}
|
# HOMEBREW_GITHUB_TOKEN: ${{ secrets.HOMEBREW_GITHUB_TOKEN }}
|
||||||
Loading…
Reference in a new issue