mirror of
https://github.com/tiennm99/mathmax.git
synced 2026-08-02 00:22:24 +00:00
feat: initial scaffold
- SvelteKit 2 + Svelte 5 + Tailwind 3 (JS only, paths.base=/mathmax) - Vietnamese landing page: hero + scope (lớp 6-9) + 3 topic cards (Số học, Đại số, Hình học) all "Sắp ra mắt" - GitHub Actions: CI (build) on PR + deploy to Pages on main - Apache-2.0 LICENSE, README, RUNBOOK, CHANGELOG
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
name: CI
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
ci:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '24'
|
||||
# TODO: add `cache: 'npm'` once package-lock.json is committed.
|
||||
|
||||
- name: Install dependencies
|
||||
# TODO: switch to `npm ci` once package-lock.json is committed.
|
||||
run: npm install --no-audit --no-fund
|
||||
|
||||
- name: Build
|
||||
run: npm run build
|
||||
@@ -0,0 +1,53 @@
|
||||
name: Deploy to GitHub Pages
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
pages: write
|
||||
id-token: write
|
||||
|
||||
concurrency:
|
||||
group: pages-deploy
|
||||
cancel-in-progress: false
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '24'
|
||||
# TODO: add `cache: 'npm'` once package-lock.json is committed.
|
||||
|
||||
- name: Install dependencies
|
||||
# TODO: switch to `npm ci` once package-lock.json is committed.
|
||||
run: npm install --no-audit --no-fund
|
||||
|
||||
- name: Build
|
||||
run: npm run build
|
||||
env:
|
||||
SITE_URL: https://tiennm99.github.io
|
||||
SITE_BASE: /mathmax
|
||||
|
||||
- name: Upload Pages artifact
|
||||
uses: actions/upload-pages-artifact@v3
|
||||
with:
|
||||
path: ./build
|
||||
|
||||
deploy:
|
||||
needs: build
|
||||
runs-on: ubuntu-latest
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deployment.outputs.page_url }}
|
||||
steps:
|
||||
- name: Deploy to GitHub Pages
|
||||
id: deployment
|
||||
uses: actions/deploy-pages@v4
|
||||
Reference in New Issue
Block a user