40 lines
1.0 KiB
YAML
40 lines
1.0 KiB
YAML
name: basebuild
|
|
|
|
on:
|
|
pull_request:
|
|
push:
|
|
|
|
jobs:
|
|
goreleaser:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Set up Node.js
|
|
uses: actions/setup-node@v3
|
|
with:
|
|
node-version: latest
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v3
|
|
with:
|
|
go-version: '>=1.18.0'
|
|
|
|
# This step usually is not needed because the /ui/dist is pregenerated locally
|
|
# but its here to ensure that each release embeds the latest admin ui artifacts.
|
|
# If the artificats differs, a "dirty error" is thrown - https://goreleaser.com/errors/dirty/
|
|
- name: Build Admin dashboard UI
|
|
run: npm --prefix=./ui ci && npm --prefix=./ui run build
|
|
|
|
- name: Run GoReleaser
|
|
uses: goreleaser/goreleaser-action@v3
|
|
with:
|
|
distribution: goreleaser
|
|
version: latest
|
|
args: release --rm-dist
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|