2025-02-09 10:50:57 -06:00
|
|
|
name: Actions
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
docs:
|
|
|
|
name: Build and Push Documentation
|
|
|
|
runs-on: docker
|
2025-02-09 10:56:15 -06:00
|
|
|
container: catthehacker/ubuntu:act-latest
|
2025-02-09 10:50:57 -06:00
|
|
|
steps:
|
|
|
|
- name: Checkout repository
|
2025-02-09 10:57:02 -06:00
|
|
|
uses: https://github.com/actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
|
2025-02-09 10:50:57 -06:00
|
|
|
- name: Set up SSH key
|
2025-02-09 10:57:02 -06:00
|
|
|
uses: https://www.coastalcommits.com/actions/ssh-agent@forgejo
|
2025-02-09 10:50:57 -06:00
|
|
|
with:
|
|
|
|
ssh-private-key: ${{ secrets.DEPLOY_KEY }}
|
|
|
|
instance-urls: "coastalcommits.com"
|
|
|
|
- name: Add instance URLs to known_hosts
|
|
|
|
run: ssh-keyscan -H coastalcommits.com >> ~/.ssh/known_hosts
|
2025-02-09 10:58:15 -06:00
|
|
|
- name: Setup Bun
|
2025-02-09 10:57:02 -06:00
|
|
|
uses: https://github.com/oven-sh/setup-bun@v2
|
2025-02-09 10:50:57 -06:00
|
|
|
with:
|
2025-02-09 10:56:15 -06:00
|
|
|
bun-version: latest
|
2025-02-09 10:50:57 -06:00
|
|
|
- name: Configure Git
|
|
|
|
run: |
|
|
|
|
git config --global user.name "CoastalCommits"
|
|
|
|
git config --global user.email "CoastalCommits@noreply@coastalcommits.com"
|
|
|
|
git remote set-url origin git@coastalcommits.com:${{ github.repository }}
|
|
|
|
- name: Install dependencies
|
2025-02-09 10:56:15 -06:00
|
|
|
run: bun install --frozen-lockfile
|
2025-02-09 10:50:57 -06:00
|
|
|
- name: Build Documentation
|
2025-02-09 10:56:15 -06:00
|
|
|
run: bun docs
|
2025-02-09 10:50:57 -06:00
|
|
|
- name: Commit and Push
|
|
|
|
run: |
|
2025-02-09 10:58:15 -06:00
|
|
|
git commit -a -m "Update documentation"
|
2025-02-09 10:50:57 -06:00
|
|
|
git push origin
|