grc20-register
is a tool designed to register Gno's GRC20 token automatically whenever new grc20 token has been successfully deployed to gno.
- Automatic GRC20 Register: Automatically registers grc20 token to target register contract.
- Concurrent Chain Indexing: Utilizes asynchronous workers for fast and efficient indexing. Data is available for serving as soon as it is fetched from the remote chain.
feature came from tx-indexer
- Embedded Database: Features PebbleDB for quick on-disk data access and migration.
feature came from tx-indexer
This section guides you through setting up and running the `grc20-register.
- Clone the Repository
git clone github.com/gnoswap-labs/grc20-register
-
Copy
.env.example
in/addpkg
to.env
at same location and change variables -
Change register template
addpkg/template.txt
Default template is for gnoswap pool, router, staker register. Use your own realm's register.
-
Build the binary
make build
- Run the grc20-register
./build/grc20-register start
It should print something like below if automatic register
2024-03-20T17:57:20.907+0900 INFO fetcher fetch/fetch.go:248 Registered grc20 token {"pkgPath": "gno.land/r/gnoswap/test_foo"}
It should print something like below if automatic register
2024-03-20T17:59:16.908+0900 ERROR fetcher fetch/fetch.go:246 Failed to register grc20 token {"pkgPath": "gno.land/r/demo/gns", "error": "transaction failed during execution, invalid package path"}