Skip to content

Commit

Permalink
ci: add cloudflare pages deploy actions
Browse files Browse the repository at this point in the history
  • Loading branch information
Th1nkK1D committed Jun 9, 2024
1 parent c8d9627 commit d060efa
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 2 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Deploy to Cloudflare Pages

on:
push:
branches: ['main']

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v1
- run: bun install
- run: bun run build
- uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
projectName: ordinaryunfold
directory: ./build
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
"lint": "eslint . --fix",
"format": "prettier --write .",
"deploy": "netlify deploy --prod --dir=build"
"format": "prettier --write ."
},
"devDependencies": {
"@rollup/plugin-dsv": "^3.0.4",
Expand Down

0 comments on commit d060efa

Please sign in to comment.