2024-07-17 16:02:16 -04:00
|
|
|
name: Deploy CDN WebComponents
|
2024-07-17 15:23:16 -04:00
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
2024-07-17 15:45:55 -04:00
|
|
|
branches:
|
2025-01-07 15:26:06 -05:00
|
|
|
- "other"
|
2024-07-17 15:23:16 -04:00
|
|
|
|
|
|
|
jobs:
|
2024-12-06 14:49:21 -05:00
|
|
|
deploy-docs:
|
2024-12-04 19:11:23 -05:00
|
|
|
permissions:
|
|
|
|
contents: write
|
2024-07-17 15:23:16 -04:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2024-07-17 15:48:50 -04:00
|
|
|
- name: Checkout code
|
|
|
|
uses: actions/checkout@v3
|
2024-12-04 21:17:05 -05:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
2024-07-17 15:48:50 -04:00
|
|
|
|
2024-12-04 21:23:36 -05:00
|
|
|
- uses: oven-sh/setup-bun@v2
|
|
|
|
with:
|
|
|
|
bun-version: latest
|
|
|
|
|
2024-12-06 14:49:21 -05:00
|
|
|
- name: Install Dependencies
|
|
|
|
run: bun install
|
2024-12-04 19:12:58 -05:00
|
|
|
|
2024-12-04 21:22:05 -05:00
|
|
|
- name: Build
|
2024-12-04 21:23:36 -05:00
|
|
|
run: bun run build
|
2024-12-04 21:22:05 -05:00
|
|
|
|
2024-12-06 14:04:33 -05:00
|
|
|
- name: Deploy Docs
|
|
|
|
uses: peaceiris/actions-gh-pages@v3
|
|
|
|
with:
|
|
|
|
publish_dir: _site
|
|
|
|
publish_branch: gh-pages
|
|
|
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
2024-12-08 14:51:16 -05:00
|
|
|
cname: nebulaui.org
|
2024-12-06 14:04:33 -05:00
|
|
|
|
2024-12-06 14:49:21 -05:00
|
|
|
publish:
|
|
|
|
needs: deploy-docs
|
|
|
|
permissions:
|
|
|
|
contents: write
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
if: contains(github.event.head_commit.modified, 'src/')
|
|
|
|
steps:
|
|
|
|
- name: Checkout code
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
|
|
|
|
- uses: oven-sh/setup-bun@v2
|
|
|
|
with:
|
|
|
|
bun-version: latest
|
|
|
|
|
|
|
|
- name: Setup Git Config
|
|
|
|
run: |
|
|
|
|
bun install
|
|
|
|
git config user.name "Prad N."
|
|
|
|
git config user.email "prad@sonr.io"
|
|
|
|
|
|
|
|
- name: Build
|
|
|
|
run: bun run build
|
|
|
|
|
2024-12-05 19:13:21 -05:00
|
|
|
- name: 'Automated Version Bump and Release'
|
2024-12-04 21:17:05 -05:00
|
|
|
run: |
|
2024-12-05 19:13:21 -05:00
|
|
|
git add .
|
|
|
|
git commit -m "chore: update build artifacts [skip ci]" || echo "No changes to commit"
|
2024-12-04 21:17:05 -05:00
|
|
|
npm version patch
|
|
|
|
git push
|
|
|
|
git push --tags
|
2024-12-04 19:11:23 -05:00
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
2024-07-17 15:48:50 -04:00
|
|
|
|
2024-12-04 19:11:23 -05:00
|
|
|
- uses: JS-DevTools/npm-publish@v3
|
2024-07-17 15:23:16 -04:00
|
|
|
with:
|
2024-12-04 19:11:23 -05:00
|
|
|
token: ${{ secrets.NPM_TOKEN }}
|