Release #84
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
workflow_dispatch: | |
permissions: | |
contents: write | |
packages: write | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- run: git fetch --force --tags | |
- name: Set outputs | |
id: vars | |
run: echo "::set-output name=latest_tag::$(git describe --tags --abbrev=0)" | |
- name: Check outputs | |
run: echo ${{ steps.vars.outputs.latest_tag }} | |
- name: find and replace metlcd version in frontend | |
uses: jacobtomlinson/gha-find-replace@v3 | |
with: | |
find: "dev" | |
replace: "${{ steps.vars.outputs.latest_tag }}" | |
include: "ui/src/version.ts" | |
regex: true | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: 8 | |
- name: build frontend | |
run: | | |
pnpm --prefix=./ui install | |
pnpm --prefix=./ui build --emptyOutDir | |
- uses: actions/setup-go@v4 | |
with: | |
go-version: stable | |
- uses: goreleaser/goreleaser-action@v5 | |
with: | |
distribution: goreleaser | |
version: latest | |
args: release --clean --skip=validate | |
env: | |
GITHUB_TOKEN: ${{ secrets.GHCR_TOKEN }} |