Skip to content

fix format

fix format #275

on:
push:
branches:
- main
name: Frontend Deploy
jobs:
deploy:
runs-on: ubuntu-latest
permissions:
contents: read
deployments: write
name: Deploy to Cloudflare Pages
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: nightly
- name: Generate Rust Undeads Json
run: cargo run && cp ./undeads.json ../frontend/undeads_rust.json
working-directory: ./runtime-rs
- name: Install LLVM and Clang
uses: KyleMayes/install-llvm-action@v1
with:
version: "13.0"
- name: Install Libs
run: sudo apt install libncurses5
- name: Generate C++ Undeads Json
run: make && ./build/runtime && cp ./undeads.json ../frontend/undeads_cpp.json
working-directory: ./runtime-cc
- uses: actions/setup-node@v3
with:
node-version: 18
- uses: bahmutov/npm-install@v1
with:
useLockFile: true
working-directory: ./frontend
- name: Build Check
run: yarn build
working-directory: ./frontend
- name: Move Valhalla Assets
run: mv valhalla-assets ./dist/
working-directory: ./frontend
- name: Publish to Cloudflare Pages
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: 3a49159509ead63f611cec6e748eea47
projectName: valhalla
directory: ./frontend/dist
branch: main