refactor(workflow): migrate from gitea to forgejo

This commit is contained in:
z0x 2025-03-23 12:32:05 -04:00
parent c71ef02381
commit 18f5369380
2 changed files with 6 additions and 6 deletions

View file

@ -0,0 +1,35 @@
name: build dist
on:
push:
branches:
- main
workflow_dispatch:
jobs:
build-dist:
runs-on: docker
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup bun.sh
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Install dependencies
run: |
bun install
bun run build
- name: Deploy to server
uses: https://github.com/appleboy/scp-action@master
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
key: ${{ secrets.SSH_PRIVATE_KEY }}
source: "dist/*"
target: ${{ secrets.TARGET }}
strip_components: 1
overwrite: true

View file

@ -0,0 +1,35 @@
name: update dependencies
on:
schedule:
- cron: '0 0 * * *'
workflow_dispatch:
jobs:
update-deps:
runs-on: docker
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup bun.sh
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Update dependencies
run: |
bun update
bun install
- name: Commit updates
run: |
git config user.name "actions[bot]"
git config user.email "actions[bot]@git.z0x.ca"
git add .
if git diff --staged --quiet; then
echo "No updates avalable"
else
git commit -m "chore(deps): bump dependencies"
git push
fi