Wagyu

Overview

Wagyu is a feature-rich command-line utility to generate cryptocurrency wallets. Wagyu enables developers to build their own cryptocurrency application using various modules.

Supported Cryptocurrencies

LibraryStandard WalletHD WalletMnemonicNetwork
wagyu-bitcoinP2PKH, P2SH-P2WPKH, Bech32BIP-32, BIP-44, BIP-49, CustomBIP-39Mainnet, Testnet
wagyu-ethereumStandardEthereum, Ledger, Trezor, Keepkey, CustomBIP-39All
wagyu-moneroStandard, Integrated, SubaddressN/AElectrumMainnet, Testnet, Stagenet
wagyu-zcashP2PKH, Sprout, SaplingZIP-32N/AMainnet, Testnet

Build Guide

Install Rust

We recommend installing Rust using rustup. You can install rustup as follows:

  • macOS or Linux:

    curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
  • Windows (64-bit):
    Download the Windows 64-bit executable and follow the on-screen instructions.

  • Windows (32-bit):
    Download the Windows 32-bit executable and follow the on-screen instructions.

Build from Homebrew (for macOS)

For macOS users, we recommend installing wagyu via Homebrew as follows:

brew install wagyu

Build from Crates.io

We recommend installing wagyu from Crates.io:

cargo install wagyu

Build from Source Code

Alternatively, you can install wagyu by building from the source code:

# Download the source code
git clone https://github.com/howardwu/wagyu
cd wagyu
 
# Build in release mode
cargo build --release

This will generate an executable under the ./target/release directory. To use wagyu, run the following command:

./target/release/wagyu

Usage Guide

Generate a Cryptocurrency Wallet

To generate a cryptocurrency wallet, run:

wagyu [CRYPTOCURRENCY] [FLAGS] [OPTIONS]

Example for Bitcoin Wallet

To generate a Bitcoin wallet, run:

wagyu bitcoin [FLAGS] [OPTIONS]

Optional parameters:

FLAGS:
    -h, --help    Prints help information
    -j, --json    Prints the generated wallet(s) in JSON format

OPTIONS:
    -c, --count <count>        Generates a specified number of wallets
    -f, --format <format>      Generates a wallet with a specified format [possible values: bech32, legacy, segwit]
    -n, --network <network>    Generates a wallet for a specified network [possible values: mainnet, testnet]

Generate an HD Cryptocurrency Wallet

To generate an HD cryptocurrency wallet, run:

wagyu [CRYPTOCURRENCY] hd [FLAGS] [OPTIONS]

Example for Bitcoin HD Wallet

To generate a Bitcoin HD wallet, run:

wagyu bitcoin hd [FLAGS] [OPTIONS]

Optional parameters:

FLAGS:
    -h, --help    Prints help information
    -j, --json    Prints the generated wallet(s) in JSON format

OPTIONS:
    -c, --count <count>              Generates a specified number of wallets
    -d, --derivation <"path">        Generates an HD wallet for a specified derivation path (in quotes) [possible values: bip32, bip44, bip49, "<custom path>"]
    -l, --language <language>        Generates an HD wallet with a specified language [possible values: chinese_simplified, chinese_traditional, english, french, italian, japanese, korean, spanish]
    -n, --network <network>          Generates an HD wallet for a specified network [possible values: mainnet, testnet]
    -p, --password <password>        Generates an HD wallet with a specified password
    -w, --word-count <word count>    Generates an HD wallet with a specified word count [possible values: 12, 15, 18, 21, 24]

Import a Cryptocurrency Wallet

To import a cryptocurrency wallet, run:

wagyu [CRYPTOCURRENCY] import [FLAGS] [OPTIONS]

Example for Bitcoin Wallet

To import a Bitcoin wallet, run:

wagyu bitcoin import [FLAGS] [OPTIONS]

Optional parameters:

FLAGS:
    -h, --help    Prints help information
    -j, --json    Prints the generated wallet(s) in JSON format

OPTIONS:
        --address <address>        Imports a partial wallet for a specified address
    -f, --format <format>          Imports a wallet with a specified format [possible values: bech32, legacy, segwit]
    -n, --network <network>        Imports a wallet for a specified network [possible values: mainnet, testnet]
        --private <private key>    Imports a wallet for a specified private key
        --public <public key>      Imports a partial wallet for a specified public key

Import an HD Cryptocurrency Wallet

To import an HD cryptocurrency wallet, run:

wagyu [CRYPTOCURRENCY] import-hd [FLAGS] [OPTIONS]

Example for Bitcoin HD Wallet

To import a Bitcoin HD wallet, run:

wagyu bitcoin import-hd [FLAGS] [OPTIONS]

Optional parameters:

FLAGS:
    -h, --help    Prints help information
    -j, --json    Prints the generated wallet(s) in JSON format

OPTIONS:
    -a, --account <account>                      Imports an HD wallet for a specified account number for bip44 and bip49 derivations
    -c, --chain <chain>                          Imports an HD wallet for a specified (external/internal) chain for bip44 and bip49 derivations [possible values: 0, 1]
    -d, --derivation <"path">                    Imports an HD wallet for a specified derivation path (in quotes) [possible values: bip32, bip44, bip49, "<custom path>"]
        --extended-private <extended private>    Imports a partial HD wallet for a specified extended private key
        --extended-public <extended public>      Imports a partial HD wallet for a specified extended public key
    -i, --index <index>                          Imports an HD wallet for a specified index
    -m, --mnemonic <"mnemonic">                  Imports an HD wallet for a specified mnemonic (in quotes)
    -

Similar Projects