feat: Upload image in PNG and SVG format (#60) #187
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: Main build & deploy | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
env: | |
NX_CLOUD_DISTRIBUTED_EXECUTION: false | |
NX_CLOUD_DISTRIBUTED_EXECUTION_AGENT_COUNT: 0 | |
NX_BRANCH: ${{ github.event.number || github.ref_name }} | |
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }} | |
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} | |
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
BRANCH_NAME: ${{ github.head_ref || github.ref_name }} | |
jobs: | |
main: | |
name: Main | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
name: Checkout [Pull Request] | |
if: ${{ github.event_name == 'pull_request' }} | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
fetch-depth: 0 | |
- uses: actions/checkout@v4 | |
name: Checkout [Default Branch] | |
if: ${{ github.event_name != 'pull_request' }} | |
with: | |
fetch-depth: 0 | |
- name: Derive appropriate SHAs for base and head for `nx affected` commands | |
uses: nrwl/nx-set-shas@v4 | |
- run: | | |
echo "BASE: ${{ env.NX_BASE }}" | |
echo "HEAD: ${{ env.NX_HEAD }}" | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: 8 | |
- name: Install Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 20 | |
cache: 'pnpm' | |
- name: Install dependencies | |
run: pnpm install --frozen-lockfile | |
- name: Run build task | |
run: pnpm nx affected -t build | |
- name: Run deploy task | |
run: pnpm nx affected -t deploy |