Bech32 Utils
bech32-utils
is a command-line tool written in Rust that allows you to transform any Bech32 prefixed address into another address with a different prefix. It's designed to be simple, efficient, and easy to use.
Installation
To install bech32-utils
, you need to have Rust and Cargo installed on your machine. If you don't have them installed, please follow the instructions here: Install Rust.
Once Rust and Cargo are installed, you can install bech32-utils
by cloning the repository and building the project:
The built binary will be located at target/release/bech32-utils
.
Usage
To use bech32-utils
, you need to provide the original Bech32 address and the prefix you want to convert it to. The tool also accepts an optional derivation path.
Or what you can do is use a csv file with records like the following <ADDRESS>,[..<EXTRA_INFO>]
(e.g. pasg000000000000000000000000000000000000000,1231241,staker,69,420
)
Parameters:
<address>
: The original Bech32 address you want to convert.<new_prefix>
: The new prefix for the address.[derivation_path]
: Optional. The derivation path if applicable.
Examples:
Convert an address to a new prefix:
Convert an address to a new prefix with a derivation path:
Contributing
Contributions are what make the open-source community such a fantastic place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement".
Don't forget to give the project a star! Thanks again!
Running from source
to run the cli commands from source run
License
Distributed under the MIT License. See LICENSE
for more information.
Contact
Maurits Bos - maurits.bos@gmail.com
Project Link: https://github.com/mbbrainz/bech32-utils