Skip to content

Commit 131869f

Browse files
committed
Refactor: Move about.md & projects.json to pub, sync CNAME and .github
0 parents  commit 131869f

10 files changed

Lines changed: 2308 additions & 0 deletions

File tree

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
name: Deploy GitHub Pages (Minified JS)
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
concurrency:
15+
group: pages
16+
cancel-in-progress: true
17+
18+
jobs:
19+
build:
20+
runs-on: ubuntu-latest
21+
steps:
22+
- name: Checkout
23+
uses: actions/checkout@v4
24+
25+
- name: Setup Node.js
26+
uses: actions/setup-node@v4
27+
with:
28+
node-version: 20
29+
30+
- name: Prepare deploy artifact
31+
run: |
32+
mkdir -p dist
33+
rsync -av --delete \
34+
--exclude ".git/" \
35+
--exclude ".github/" \
36+
--exclude "dist/" \
37+
./ dist/
38+
39+
- name: Minify JavaScript
40+
working-directory: dist
41+
run: |
42+
npm install --no-save terser
43+
find . -type f -name "*.js" ! -name "*.min.js" -print0 | while IFS= read -r -d '' file; do
44+
npx terser "$file" --compress --mangle --output "$file"
45+
done
46+
47+
- name: Setup Pages
48+
uses: actions/configure-pages@v5
49+
50+
- name: Upload Pages artifact
51+
uses: actions/upload-pages-artifact@v3
52+
with:
53+
path: dist
54+
55+
deploy:
56+
environment:
57+
name: github-pages
58+
url: ${{ steps.deployment.outputs.page_url }}
59+
runs-on: ubuntu-latest
60+
needs: build
61+
steps:
62+
- name: Deploy to GitHub Pages
63+
id: deployment
64+
uses: actions/deploy-pages@v4

.gitignore

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Antigravity/Agent working files
2+
sync-and-push.ps1
3+
sync-and-push.bat
4+
task.md
5+
.agent/
6+
.agent
7+
8+
# Operating system files
9+
Thumbs.db
10+
Desktop.ini
11+
.DS_Store

CNAME

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
javagar.me

0 commit comments

Comments
 (0)