Skip to content

Commit

Permalink
deploy on cf pages
Browse files Browse the repository at this point in the history
  • Loading branch information
ading2210 committed Jan 12, 2025
1 parent 7e97020 commit 439e5ab
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 0 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
on: [push]

jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
deployments: write
name: Publish to Cloudflare Pages
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Build
run: |
python3 -m venv .venv
CFLAGS=-O1 ./build.sh
cp index.html out
rm out/compiled.js
- name: Publish to Cloudflare Pages
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: b8079ffa92c97010f2a8d759e24cc782
projectName: doompdf
directory: out
9 changes: 9 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="refresh" content="0; url=/doom.pdf">
</head>
<body>
<p>Redirecting to <a href="/doom.pdf">/doom.pdf</a>...</p>
</body>
</html>

0 comments on commit 439e5ab

Please sign in to comment.