Initial Commit
This commit is contained in:
commit
0534f88f70
14 changed files with 5590 additions and 0 deletions
74
.forgejo/workflows/release.yml
Normal file
74
.forgejo/workflows/release.yml
Normal file
|
|
@ -0,0 +1,74 @@
|
|||
name: Release Site
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v*"
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
wry_ref:
|
||||
description: "Branch, tag, or commit to build from in the Wry repository"
|
||||
required: false
|
||||
default: "workspace-refactor"
|
||||
|
||||
jobs:
|
||||
release:
|
||||
runs-on: docker
|
||||
steps:
|
||||
- name: Checkout docs
|
||||
uses: https://data.forgejo.org/actions/checkout@v6
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Checkout Wry
|
||||
shell: bash
|
||||
run: |
|
||||
set -euo pipefail
|
||||
mkdir -p ~/.ssh
|
||||
printf '%s\n' "${{ secrets.WRY_DEPLOY_KEY }}" > ~/.ssh/wry_deploy_key
|
||||
chmod 600 ~/.ssh/wry_deploy_key
|
||||
ssh-keyscan git.wry.land >> ~/.ssh/known_hosts
|
||||
|
||||
WRY_REF="${{ inputs.wry_ref }}"
|
||||
if [ -z "$WRY_REF" ]; then
|
||||
WRY_REF="workspace-refactor"
|
||||
fi
|
||||
|
||||
GIT_SSH_COMMAND="ssh -i ~/.ssh/wry_deploy_key -o IdentitiesOnly=yes" \
|
||||
git clone --depth 1 --branch "$WRY_REF" \
|
||||
ssh://forgejo@git.wry.land/kossLAN/wry.git _wry
|
||||
|
||||
- name: Setup Node
|
||||
uses: https://data.forgejo.org/actions/setup-node@v6
|
||||
with:
|
||||
node-version: 24
|
||||
cache: pnpm
|
||||
cache-dependency-path: pnpm-lock.yaml
|
||||
|
||||
- name: Install dependencies
|
||||
shell: bash
|
||||
run: |
|
||||
set -euo pipefail
|
||||
corepack enable
|
||||
pnpm install --frozen-lockfile
|
||||
|
||||
- name: Build site
|
||||
shell: bash
|
||||
run: |
|
||||
set -euo pipefail
|
||||
WRY_REPO_PATH="$PWD/_wry" pnpm run build
|
||||
|
||||
- name: Package release assets
|
||||
shell: bash
|
||||
run: |
|
||||
set -euo pipefail
|
||||
TAG="${{ forge.ref_name }}" pnpm run release:pack
|
||||
|
||||
- name: Upload Forgejo release
|
||||
uses: https://data.forgejo.org/actions/forgejo-release@v2.13.0
|
||||
with:
|
||||
direction: upload
|
||||
tag: ${{ forge.ref_name }}
|
||||
release-dir: dist/release
|
||||
release-notes-file: dist/release/RELEASE_NOTES.md
|
||||
override: true
|
||||
Loading…
Add table
Add a link
Reference in a new issue