- nix:
nix develop
- other Linux and macOS:
./dev-setup.sh; source .venv/bin/activate
- CL - Consensus Layer, Waves;
- EL - Execution Layer, Ethereum.
Run any command without parameters to see the full list of options.
u0-transfer-c2e
u0-transfer-e2c
If you transfer a native token (Unit0), then you don't need to approve transfers for it. Otherwise, run approve command before transferring assets.
You have to do this for registered asset transfers.
u0-erc20-approve
In case if a transfer failed during the process.
You will need an EL transaction with a transfer from the logs and specify it in --txn-hash
parameter.
u0-transfer-e2c-withdraw --txn-hash <Ethereum transaction hash in HEX>
Instead of providing arguments, you can write a JSON file and load arguments from it using --args path/to/args.json
.
Here is an example for consensus client local-network:
{
"waves_private_key": "DwPvPGEp3LPg5gVRz7Pqd8mHa6dWK9dXtP4XDmKTz6ga",
"eth_private_key": "0x8f2a55949038a9610f50fb23b5883af3b4ecb3c3bb792cbcefbd1542c692be63",
"network_settings": {
"name": "LocalNet",
"cl_chain_id_str": "D",
"cl_node_api_url": "http://127.0.0.1:16869",
"el_node_api_url": "http://127.0.0.1:18545",
"chain_contract_address": "3FXDd4LoxxqVLfMk8M25f8CQvfCtGMyiXV1"
},
"asset_name": "TestToken"
}
See all available options in ArgsData.
CLI arguments has precedence over JSON arguments.
You can configure the logging with a custom logging.conf (docs).
The precedence (from higher to lower) of config files:
- A path to the
logging.conf
file in theLOGGING_CONFIG
environment variable. - The
logging.conf
file in the current working directory. - The default
logging.conf
file in theunit0-examples
package.