How can I initialize a user's balance in a Substrate blockchain?
问题 When I start my Substrate blockchain, I want to initialize users with some free balance. How can I achieve this? What if my chain is already running and I do not want to restart it? 回答1: Genesis Configuration The best way to set up your Substrate users with some initial free balance is to update your chain_spec.rs file such that users are given units at the genesis block of your blockchain. This genesis configuration happens through the Balances module: fn testnet_genesis(initial_authorities: