chore: bump sablier sdk #41
This file contains hidden or 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: CD | |
| # Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. | |
| # However, do NOT cancel in-progress runs as we want to allow these production deployments to complete. | |
| concurrency: | |
| cancel-in-progress: false | |
| group: pages | |
| # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| on: | |
| push: | |
| branches: [main] | |
| workflow_dispatch: | |
| jobs: | |
| # ---------------------------------------------------------------------------- # | |
| # RUN TESTS # | |
| # ---------------------------------------------------------------------------- # | |
| # Run all CI validation tests | |
| ci: | |
| uses: ./.github/workflows/ci.yml | |
| secrets: inherit | |
| # ---------------------------------------------------------------------------- # | |
| # DEPLOYMENT # | |
| # ---------------------------------------------------------------------------- # | |
| deploy: | |
| name: Deploy Token List | |
| needs: [ci] | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: production | |
| url: ${{ steps.pages-deployment.outputs.page_url }} | |
| steps: | |
| # ---------------------------------------------------------------------------- # | |
| # SETUP & BUILD # | |
| # ---------------------------------------------------------------------------- # | |
| - uses: actions/checkout@v5 | |
| - uses: sablier-labs/devkit/actions/setup@main | |
| - name: Restore build cache | |
| id: build-cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: token-list/*.json | |
| key: token-lists-${{ hashFiles('scripts/token-list/**', 'token-list/evm/**/*.json', 'token-list/solana/**/*.json', 'package.json') }} | |
| restore-keys: | | |
| token-lists- | |
| - name: Build token lists | |
| if: steps.build-cache.outputs.cache-hit != 'true' | |
| run: just build | |
| # ---------------------------------------------------------------------------- # | |
| # GITHUB PAGES # | |
| # ---------------------------------------------------------------------------- # | |
| - name: Set up GitHub Pages | |
| uses: actions/configure-pages@v5 | |
| - name: Build with Jekyll | |
| uses: actions/jekyll-build-pages@v1 | |
| with: | |
| source: ./ | |
| destination: ./_site | |
| - name: Upload site as artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: _site | |
| - name: Deploy to GitHub Pages | |
| id: pages-deployment | |
| uses: actions/deploy-pages@v4 | |
| # ---------------------------------------------------------------------------- # | |
| # UPLOAD ARTIFACTS # | |
| # ---------------------------------------------------------------------------- # | |
| - name: Upload EVM token list artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: evm-token-list | |
| path: token-list/evm.json | |
| - name: Upload Solana token list artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: solana-token-list | |
| path: token-list/solana.json | |
| # ---------------------------------------------------------------------------- # | |
| # EVM DEPLOYMENT # | |
| # ---------------------------------------------------------------------------- # | |
| deploy-evm: | |
| name: Deploy EVM Token List | |
| needs: [ci, deploy] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Download EVM token list artifact | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: evm-token-list | |
| - name: Deploy and pin EVM list to IPFS | |
| id: ipfs-deployment | |
| uses: anantaramdas/ipfs-pinata-deploy-action@a551f37c17ec3961df7c3ad52e1cd266dfd3d7e7 | |
| with: | |
| path: ./evm.json | |
| pin-name: Sablier EVM Token List | |
| pinata-api-key: ${{ secrets.PINATA_API_KEY }} | |
| pinata-secret-api-key: ${{ secrets.PINATA_API_SECRET_KEY }} | |
| - name: Deploy to Cloudflare Web3 Gateway | |
| uses: Uniswap/cloudflare-update-web3-gateway@master | |
| env: | |
| CLOUDFLARE_GATEWAY_ID: ${{ secrets.CLOUDFLARE_GATEWAY_ID_EVM }} | |
| CLOUDFLARE_TOKEN: ${{ secrets.CLOUDFLARE_TOKEN }} | |
| CLOUDFLARE_ZONE_ID: ${{ secrets.CLOUDFLARE_ZONE_ID }} | |
| with: | |
| cid: ${{ steps.ipfs-deployment.outputs.hash }} | |
| - name: Add EVM deployment summary | |
| run: | #shell | |
| echo "## EVM Token List Deployment" >> $GITHUB_STEP_SUMMARY | |
| echo "✅ Passed" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "### Deployment Details" >> $GITHUB_STEP_SUMMARY | |
| echo "- **IPFS Hash**: \`${{ steps.ipfs-deployment.outputs.hash }}\`" >> $GITHUB_STEP_SUMMARY | |
| echo "- **IPFS Gateway**: https://ipfs.io/ipfs/${{ steps.ipfs-deployment.outputs.hash }}" >> $GITHUB_STEP_SUMMARY | |
| echo "- **Commit**: ${{ github.sha }}" >> $GITHUB_STEP_SUMMARY | |
| echo "- **Total Tokens**: $(jq '.tokens | length' evm.json)" >> $GITHUB_STEP_SUMMARY | |
| echo "- **Chains**: $(jq '[.tokens[].chainId] | unique | length' evm.json)" >> $GITHUB_STEP_SUMMARY | |
| # ---------------------------------------------------------------------------- # | |
| # SOLANA DEPLOYMENT # | |
| # ---------------------------------------------------------------------------- # | |
| deploy-solana: | |
| name: Deploy Solana Token List | |
| needs: [ci, deploy] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Download Solana token list artifact | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: solana-token-list | |
| - name: Deploy and pin Solana list to IPFS | |
| id: ipfs-deployment | |
| uses: anantaramdas/ipfs-pinata-deploy-action@a551f37c17ec3961df7c3ad52e1cd266dfd3d7e7 | |
| with: | |
| path: ./solana.json | |
| pin-name: Sablier Solana Token List | |
| pinata-api-key: ${{ secrets.PINATA_API_KEY }} | |
| pinata-secret-api-key: ${{ secrets.PINATA_API_SECRET_KEY }} | |
| - name: Deploy to Cloudflare Web3 Gateway | |
| uses: Uniswap/cloudflare-update-web3-gateway@master | |
| env: | |
| CLOUDFLARE_GATEWAY_ID: ${{ secrets.CLOUDFLARE_GATEWAY_ID_SOLANA }} | |
| CLOUDFLARE_TOKEN: ${{ secrets.CLOUDFLARE_TOKEN }} | |
| CLOUDFLARE_ZONE_ID: ${{ secrets.CLOUDFLARE_ZONE_ID }} | |
| with: | |
| cid: ${{ steps.ipfs-deployment.outputs.hash }} | |
| - name: Add Solana deployment summary | |
| run: | #shell | |
| echo "## Solana Token List Deployment" >> $GITHUB_STEP_SUMMARY | |
| echo "✅ Passed" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "### Deployment Details" >> $GITHUB_STEP_SUMMARY | |
| echo "- **IPFS Hash**: \`${{ steps.ipfs-deployment.outputs.hash }}\`" >> $GITHUB_STEP_SUMMARY | |
| echo "- **IPFS Gateway**: https://ipfs.io/ipfs/${{ steps.ipfs-deployment.outputs.hash }}" >> $GITHUB_STEP_SUMMARY | |
| echo "- **Commit**: ${{ github.sha }}" >> $GITHUB_STEP_SUMMARY | |
| echo "- **Total Tokens**: $(jq '.tokens | length' solana.json)" >> $GITHUB_STEP_SUMMARY |