Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Deploy Wallpaper Gallery to GitHub Pages

on:
push:
branches: [ main ]
workflow_dispatch:
schedule:
- cron: '0 0 * * 0' # Weekly rebuild

permissions:
contents: write

jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: 'npm'

- name: Install Dependencies
run: npm ci

- name: Build Gallery & Generate Manifest
run: npm run build

- name: Deploy to gh-pages branch
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: dist
branch: gh-pages
19 changes: 18 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,18 @@
effects
# Dependencies
node_modules/

# Build outputs
dist/
.astro/

# Environment files
.env
.env.*
!.env.example

# Logs & temp
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
effects
14 changes: 14 additions & 0 deletions astro.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { defineConfig } from 'astro/config';
import tailwind from '@astrojs/tailwind';

const owner = process.env.GITHUB_REPOSITORY_OWNER || 'rootagi';

// https://astro.build/config
export default defineConfig({
site: `https://${owner}.github.io`,
base: '/wallpaper',
integrations: [tailwind()],
build: {
format: 'directory'
}
});
Loading