Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: added ERC-1155 to ERC Registry Indexer workflow #1176

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 16 additions & 6 deletions .github/workflows/erc-registry-indexer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,17 @@ jobs:
NEW_ERC721_RECORDS=$(jq '. | length' erc-registry/${{ github.event.inputs.HEDERA_NETWORK }}/erc-721.json)
fi

# Determine the new amount of ERC-1155 records
if [ -f backup/erc-1155.json ]; then
NEW_ERC1155_RECORDS=$(jq -s '.[1] - .[0] | length' backup/erc-1155.json erc-registry/${{ github.event.inputs.HEDERA_NETWORK }}/erc-1155.json)
else
NEW_ERC1155_RECORDS=$(jq '. | length' erc-registry/${{ github.event.inputs.HEDERA_NETWORK }}/erc-1155.json)
fi

# Export the results to GitHub environment variables
echo "NEW_ERC20_RECORDS=${NEW_ERC20_RECORDS}" >> $GITHUB_ENV
echo "NEW_ERC721_RECORDS=${NEW_ERC721_RECORDS}" >> $GITHUB_ENV
echo "NEW_ERC1155_RECORDS=${NEW_ERC1155_RECORDS}" >> $GITHUB_ENV

- name: Delete backup registry folder
run: |
Expand Down Expand Up @@ -144,22 +152,23 @@ jobs:
uses: peter-evans/create-pull-request@67ccf781d68cd99b580ae25a5c18a1cc84ffff1f # v7.0.6
with:
branch: ERC-Registry-Periodical-Update/${{ github.run_id }}
commit-message: 'chore: update ERC Registry with latest ERC-20 and ERC-721 tokens on Hedera ${{github.event.inputs.HEDERA_NETWORK}}'
commit-message: 'chore: update ERC Registry with latest ERC-20, ERC-721, and ERC-1155 tokens on Hedera ${{github.event.inputs.HEDERA_NETWORK}}'
committer: ${{ steps.gpg_importer.outputs.name }} <${{ steps.gpg_importer.outputs.email }}>
author: ${{ steps.gpg_importer.outputs.name }} <${{ steps.gpg_importer.outputs.email }}>
token: ${{ secrets.GH_ACCESS_TOKEN }}
delete-branch: true
signoff: true
title: 'chore: update ERC Registry with latest ERC-20 and ERC-721 tokens on Hedera ${{github.event.inputs.HEDERA_NETWORK}}'
title: 'chore: update ERC Registry with latest ERC-20, ERC-721, and ERC-1155 tokens on Hedera ${{github.event.inputs.HEDERA_NETWORK}}'
body: >
**Description**:

This PR updates the ERC Registry to include the most recent ERC-20 and ERC-721 tokens.
This PR updates the ERC Registry to include the most recent ERC-20, ERC-721, and ERC-1155 tokens.

**Registry Update Summary**:
- **Hedera Network**: ${{ github.event.inputs.HEDERA_NETWORK }}
- **New ERC-20 Records Added**: ${{ env.NEW_ERC20_RECORDS }}
- **New ERC-721 Records Added**: ${{ env.NEW_ERC721_RECORDS }}
- **New ERC-1155 Records Added**: ${{ env.NEW_ERC1155_RECORDS }}
- **Indexing Duration**: ${{ env.INDEXING_DURATION }}
- **Last Indexed Time**: ${{ env.CURRENT_DATE }}
labels: 'internal'
Expand All @@ -186,22 +195,23 @@ jobs:
uses: peter-evans/create-pull-request@67ccf781d68cd99b580ae25a5c18a1cc84ffff1f # v7.0.6
with:
branch: ERC-Registry-Periodical-Update/${{ github.run_id }}
commit-message: 'chore: update ERC Registry with latest ERC-20 and ERC-721 tokens on Hedera ${{github.event.inputs.HEDERA_NETWORK}}'
commit-message: 'chore: update ERC Registry with latest ERC-20, ERC-721, and ERC-1155 tokens on Hedera ${{github.event.inputs.HEDERA_NETWORK}}'
committer: ${{ steps.gpg_importer.outputs.name }} <${{ steps.gpg_importer.outputs.email }}>
author: ${{ steps.gpg_importer.outputs.name }} <${{ steps.gpg_importer.outputs.email }}>
token: ${{ secrets.GH_ACCESS_TOKEN_MIRROR_NODE_EXPLORER }}
delete-branch: true
signoff: true
title: 'chore: update ERC Registry with latest ERC-20 and ERC-721 tokens on Hedera ${{github.event.inputs.HEDERA_NETWORK}}'
title: 'chore: update ERC Registry with latest ERC-20, ERC-721, and ERC-1155 tokens on Hedera ${{github.event.inputs.HEDERA_NETWORK}}'
body: >
**Description**:

This PR updates the ERC Registry to include the most recent ERC-20 and ERC-721 tokens.
This PR updates the ERC Registry to include the most recent ERC-20, ERC-721, and ERC-1155 tokens.

**Registry Update Summary**:
- **Hedera Network**: ${{ github.event.inputs.HEDERA_NETWORK }}
- **New ERC-20 Records Added**: ${{ env.NEW_ERC20_RECORDS }}
- **New ERC-721 Records Added**: ${{ env.NEW_ERC721_RECORDS }}
- **New ERC-1155 Records Added**: ${{ env.NEW_ERC1155_RECORDS }}
- **Indexing Duration**: ${{ env.INDEXING_DURATION }}
- **Last Indexed Time**: ${{ env.CURRENT_DATE }}
labels: 'internal'
Expand Down
Loading