ci(ui): add github workflows and issue templates

This commit is contained in:
Tuan-Dat Tran
2026-02-23 13:48:28 +01:00
parent 4198b91498
commit 36b5a62953
6 changed files with 258 additions and 0 deletions

55
.github/workflows/deploy.yml vendored Normal file
View File

@@ -0,0 +1,55 @@
name: Deploy to GitHub Pages
on:
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: "pages"
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build
env:
BASE_URL: /${{ github.event.repository.name }}/
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: 'dist'
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4

37
.github/workflows/stale.yml vendored Normal file
View File

@@ -0,0 +1,37 @@
name: Stale Issues
on:
schedule:
- cron: '30 1 * * *'
workflow_dispatch:
jobs:
stale:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
steps:
- uses: actions/stale@v9
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
days-before-issue-stale: 60
days-before-issue-close: 14
days-before-pr-stale: 30
days-before-pr-close: 14
stale-issue-message: |
This issue has been automatically marked as stale because it has not had recent activity.
It will be closed if no further activity occurs within 14 days.
Thank you for your contributions.
stale-pr-message: |
This PR has been automatically marked as stale because it has not had recent activity.
It will be closed if no further activity occurs within 14 days.
Thank you for your contributions.
close-issue-message: |
This issue was closed because it has been stalled for 14 days with no activity.
close-pr-message: |
This PR was closed because it has been stalled for 14 days with no activity.
stale-issue-label: 'stale'
stale-pr-label: 'stale'
exempt-issue-labels: 'pinned,security,bug'
exempt-pr-labels: 'pinned,security'