This commit is contained in:
commit
ed45fa303c
9 changed files with 290 additions and 0 deletions
23
.forgejo/workflows/ci.yaml
Normal file
23
.forgejo/workflows/ci.yaml
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
name: CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
- feature/*
|
||||
|
||||
jobs:
|
||||
Build:
|
||||
runs-on: docker
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
- name: Setup Go
|
||||
uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: 1.25
|
||||
- name: Test
|
||||
run: |
|
||||
set -xue
|
||||
go get ./...
|
||||
go test -p 1 ./...
|
||||
101
.forgejo/workflows/release.yaml
Normal file
101
.forgejo/workflows/release.yaml
Normal file
|
|
@ -0,0 +1,101 @@
|
|||
name: Release
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- 'v*'
|
||||
|
||||
jobs:
|
||||
Build:
|
||||
runs-on: docker
|
||||
services:
|
||||
localstack:
|
||||
image: localstack/localstack
|
||||
ports:
|
||||
- "4566:4566"
|
||||
env:
|
||||
SERVICES: ssm,dynamodb
|
||||
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: Test
|
||||
run: |
|
||||
set -xue
|
||||
go get ./...
|
||||
go test -p 1 ./...
|
||||
env:
|
||||
TEST_DYNAMO_URL: "http://localstack:4566"
|
||||
GOPRIVATE: "github:com/lmika/*"
|
||||
|
||||
# Site:
|
||||
# needs: Build
|
||||
# runs-on: docker
|
||||
# env:
|
||||
# NETLIFY_SITE_ID: set me
|
||||
# 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: Setup Dependencies
|
||||
run: |
|
||||
brew install gpg
|
||||
- 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
|
||||
run: |
|
||||
goreleaser release -f goreleaser.yml --skip=validate --clean
|
||||
env:
|
||||
GITEA_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
HOMEBREW_TAP_PRIVATE_KEY: ${{ secrets.HOMEBREW_TAP_PRIVATE_KEY }}
|
||||
MACOS_SIGN_P12: ${{ secrets.MACOS_SIGN_P12 }}
|
||||
MACOS_SIGN_PASSWORD: ${{ secrets.MACOS_SIGN_PASSWORD }}
|
||||
MACOS_NOTARY_KEY: ${{ secrets.MACOS_NOTARY_KEY }}
|
||||
MACOS_NOTARY_KEY_ID: ${{ secrets.MACOS_NOTARY_KEY_ID }}
|
||||
MACOS_NOTARY_ISSUER_ID: ${{ secrets.MACOS_NOTARY_ISSUER_ID }}
|
||||
Loading…
Add table
Add a link
Reference in a new issue