Skip to content

chore: update canary release action #48

chore: update canary release action

chore: update canary release action #48

name: Canary Release
on: workflow_dispatch
jobs:
# 1) Fill the project name to be used in NPM
env:
PROJECT_NAME: '@defi-wonderland/prophet-core'
# 2) Remove the following line if you wish to export your Solidity contracts and interfaces and publish them to NPM
if: false

Check failure on line 12 in .github/workflows/interfaces-canary.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/interfaces-canary.yml

Invalid workflow file

You have an error in your yaml syntax on line 12
export:
name: Generate Interfaces And Contracts
runs-on: ubuntu-latest
strategy:
matrix:
export_type: ['interfaces', 'all']
env:
EXPORT_NAME: ${{ matrix.export_type == 'interfaces' && '-interfaces' || '' }}
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly
- name: Install Node
uses: actions/setup-node@v4
with:
registry-url: 'https://registry.npmjs.org'
node-version: 20.x
cache: 'yarn'
- name: Install dependencies
run: yarn --frozen-lockfile
- name: Build project and generate out directory
run: yarn build
- name: Update version
run: yarn version --new-version "0.0.0-${GITHUB_SHA::8}" --no-git-tag-version
- name: Export Solidity - Export Type ${{ matrix.export_type }}
uses: defi-wonderland/[email protected]
with:
package_name: ${{ env.PROJECT_NAME }}
out: 'out'
interfaces: 'solidity/interfaces'
contracts: 'solidity/contracts'
libraries: "solidity/libraries"
export_type: '${{ matrix.export_type }}'
- name: Publish to NPM - Export Type ${{ matrix.export_type }}
run: cd export/${{ env.PROJECT_NAME }}${{ env.EXPORT_NAME }} && npm publish --access public --tag canary
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}