mirror of
https://github.com/tiennm99/iammiti99.git
synced 2026-10-13 02:14:46 +00:00
feat: implement config-driven link page
Single-page link-in-bio site at config.yaml -> build.js -> _site/index.html. Links flagged with `repo: owner/name` get live star count and last-commit age decoration from the GitHub REST API at build time. Stack: vanilla HTML/CSS output, Node 20 build script (sole dep: js-yaml). Deploy: GitHub Actions Pages artifact, daily cron + push triggers. Architecture inspired by linkyee (MIT); no source code copied. See NOTICE.
This commit is contained in:
1 parent
9fca485f14
commit
a90cb8126a
11 files changed
+589
-4
No files matched your search
@@ -0,0 +1,48 @@
|
||||
name: Deploy to Pages
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
schedule:
|
||||
# Daily 00:00 UTC — refreshes stars + last-commit decoration on repo links.
|
||||
- cron: "0 0 * * *"
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
pages: write
|
||||
id-token: write
|
||||
|
||||
concurrency:
|
||||
group: pages
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
build-and-deploy:
|
||||
runs-on: ubuntu-latest
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deploy.outputs.page_url }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 20
|
||||
cache: npm
|
||||
|
||||
- run: npm ci
|
||||
|
||||
- name: Build site
|
||||
run: node build.js
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- uses: actions/configure-pages@v5
|
||||
|
||||
- uses: actions/upload-pages-artifact@v3
|
||||
with:
|
||||
path: _site
|
||||
|
||||
- id: deploy
|
||||
uses: actions/deploy-pages@v4
|
||||
Reference in new issue
Block a user