Skip to content

Commit 2178140

Browse files
committed
Testing a template workflow
0 parents  commit 2178140

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

102 files changed

+17468
-0
lines changed

.env.development

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Development Environment Configuration
2+
VITE_BASE_PATH=/

.env.example

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Environment Configuration Examples
2+
# Copy this file to .env.development or .env.production and configure for your deployment
3+
4+
# For local development (default)
5+
VITE_BASE_PATH=/
6+
7+
# For GitHub Pages deployment (replace with your repository name)
8+
# VITE_BASE_PATH=/unity-cheat-sheet
9+
10+
# For custom domain deployment
11+
# VITE_BASE_PATH=/
12+
13+
# For subdirectory deployment
14+
# VITE_BASE_PATH=/docs

.env.production

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Production Environment Configuration for GitHub Pages
2+
# Set this to your GitHub repository name
3+
VITE_BASE_PATH=/react-github-workflow

.github/workflows/deploy.yml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
name: Deploy to GitHub Pages
2+
3+
on:
4+
push:
5+
branches:
6+
- main # Change to 'master' if that's your default branch
7+
workflow_dispatch: # Allows manual trigger from Actions tab
8+
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
concurrency:
15+
group: "pages"
16+
cancel-in-progress: false
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: Setup pnpm
31+
uses: pnpm/action-setup@v3
32+
with:
33+
version: 8
34+
35+
- name: Install dependencies
36+
run: pnpm install
37+
38+
- name: Build
39+
run: pnpm build
40+
41+
- name: Setup Pages
42+
uses: actions/configure-pages@v4
43+
44+
- name: Upload artifact
45+
uses: actions/upload-pages-artifact@v3
46+
with:
47+
path: './dist/public'
48+
49+
deploy:
50+
environment:
51+
name: github-pages
52+
url: ${{ steps.deployment.outputs.page_url }}
53+
runs-on: ubuntu-latest
54+
needs: build
55+
steps:
56+
- name: Deploy to GitHub Pages
57+
id: deployment
58+
uses: actions/deploy-pages@v4

.gitignore

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
# Dependencies
2+
**/node_modules
3+
.pnpm-store/
4+
5+
# Build outputs
6+
dist/
7+
build/
8+
*.dist
9+
10+
# Environment variables
11+
.env
12+
.env.local
13+
.env.development.local
14+
.env.test.local
15+
.env.production.local
16+
17+
# IDE and editor files
18+
.vscode/
19+
.idea/
20+
*.swp
21+
*.swo
22+
*~
23+
24+
# OS generated files
25+
.DS_Store
26+
.DS_Store?
27+
._*
28+
.Spotlight-V100
29+
.Trashes
30+
ehthumbs.db
31+
Thumbs.db
32+
33+
# Logs
34+
logs
35+
*.log
36+
npm-debug.log*
37+
yarn-debug.log*
38+
yarn-error.log*
39+
pnpm-debug.log*
40+
lerna-debug.log*
41+
42+
# Runtime data
43+
pids
44+
*.pid
45+
*.seed
46+
*.pid.lock
47+
48+
# Coverage directory used by tools like istanbul
49+
coverage/
50+
*.lcov
51+
52+
# nyc test coverage
53+
.nyc_output
54+
55+
# Dependency directories
56+
jspm_packages/
57+
58+
# TypeScript cache
59+
*.tsbuildinfo
60+
61+
# Optional npm cache directory
62+
.npm
63+
64+
# Optional eslint cache
65+
.eslintcache
66+
67+
# Microbundle cache
68+
.rpt2_cache/
69+
.rts2_cache_cjs/
70+
.rts2_cache_es/
71+
.rts2_cache_umd/
72+
73+
# Optional REPL history
74+
.node_repl_history
75+
76+
# Output of 'npm pack'
77+
*.tgz
78+
79+
# Yarn Integrity file
80+
.yarn-integrity
81+
82+
# parcel-bundler cache (https://parceljs.org/)
83+
.cache
84+
.parcel-cache
85+
86+
# Next.js build output
87+
.next
88+
89+
# Nuxt.js build / generate output
90+
.nuxt
91+
92+
# Gatsby files
93+
.cache/
94+
95+
# Storybook build outputs
96+
.out
97+
.storybook-out
98+
99+
# Temporary folders
100+
tmp/
101+
temp/
102+
103+
# Database
104+
*.db
105+
*.sqlite
106+
*.sqlite3

.gitkeep

Whitespace-only changes.

.prettierignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
dist
2+
node_modules
3+
.git
4+
*.min.js
5+
*.min.css

.prettierrc

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"semi": true,
3+
"trailingComma": "es5",
4+
"singleQuote": false,
5+
"printWidth": 80,
6+
"tabWidth": 2,
7+
"useTabs": false,
8+
"bracketSpacing": true,
9+
"bracketSameLine": false,
10+
"arrowParens": "avoid",
11+
"endOfLine": "lf",
12+
"quoteProps": "as-needed",
13+
"jsxSingleQuote": false,
14+
"proseWrap": "preserve"
15+
}

0 commit comments

Comments
 (0)