new sdk v #303
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: warp-protocol-app | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- main | |
- test | |
- beta | |
- feature/latest_updates_migration | |
paths: | |
- apps/warp-protocol/** | |
- .github/workflows/apps-warp-protocol.yml | |
pull_request: | |
branches: | |
- main | |
- test | |
- beta | |
- feature/latest_updates_migration | |
paths: | |
- apps/warp-protocol/** | |
- .github/workflows/apps-warp-protocol.yml | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
deployments: write | |
name: Publish to Cloudflare Pages | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Unzip fonts | |
run: | | |
cd apps/warp-protocol/public | |
unzip -qoP ${{ secrets.PWFONTS }} fonts.zip | |
cd ../../.. | |
- name: Get yarn cache dir | |
id: yarn-cache-dir-path | |
run: echo "::set-output name=dir::$(yarn config get cacheFolder)" | |
- name: Cache yarn | |
uses: actions/cache@v3 | |
id: yarn-cache | |
with: | |
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | |
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.os }}-yarn- | |
- name: Install dependencies | |
run: yarn install | |
working-directory: ./apps/warp-protocol | |
- name: Build source code. | |
run: yarn run build | |
working-directory: ./apps/warp-protocol | |
- id: publish | |
name: Publish to Cloudflare Pages | |
# if: contains(fromJson('["push", "synchronize"]'), github.event_name) | |
uses: cloudflare/pages-action@1 | |
with: | |
apiToken: ${{ secrets.CLOUDFLARE_PAGES_TOKEN }} | |
accountId: 620ff29bbd515d2848f5306578bd1d1d | |
projectName: warp-protocol-app | |
directory: apps/warp-protocol/build | |
gitHubToken: ${{ secrets.GITHUB_TOKEN }} | |
outputs: | |
url: ${{ steps.publish.outputs.url }} |