mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-31 12:11:02 +00:00
Rialto to Millau Transfer Generator (#568)
* Add option to relay for sending transfers to Millau chain * Endow derived accounts on Millau chain * Update message generator entrypoint script to send transfers * Use correct command when sending messages * Send Root messages from Root origin on source chain * Wrap calls from Root Origin in Sudo Call * Allow Root to send messages without paying fees * Use correct variable when sending messages to Rialto * Print warning if no message type is provided to script. * Add note mentioning that certain source origins aren't supported yet * Use correct runtime when initializing header sync * Remove option to send messages as Root * Remove endowment of derived Root accounts * Fix indentation. Co-authored-by: Tomasz Drwięga <tomasz@parity.io>
This commit is contained in:
committed by
Bastian Köcher
parent
ee655b1057
commit
f26775d690
@@ -138,12 +138,15 @@ pub enum Command {
|
||||
/// Hex-encoded lane id.
|
||||
#[structopt(long)]
|
||||
lane: HexLaneId,
|
||||
/// Message type.
|
||||
#[structopt(long, possible_values = &ToMillauMessage::variants())]
|
||||
message: ToMillauMessage,
|
||||
/// Delivery and dispatch fee.
|
||||
#[structopt(long)]
|
||||
fee: bp_rialto::Balance,
|
||||
/// Message type.
|
||||
#[structopt(subcommand)]
|
||||
message: ToMillauMessage,
|
||||
/// The origin to use when dispatching the message on the target chain.
|
||||
#[structopt(long, possible_values = &Origins::variants())]
|
||||
origin: Origins,
|
||||
},
|
||||
}
|
||||
|
||||
@@ -161,19 +164,24 @@ pub enum ToRialtoMessage {
|
||||
},
|
||||
}
|
||||
|
||||
arg_enum! {
|
||||
#[derive(Debug)]
|
||||
/// All possible messages that may be delivered to the Millau chain.
|
||||
pub enum ToMillauMessage {
|
||||
Remark,
|
||||
}
|
||||
/// All possible messages that may be delivered to the Millau chain.
|
||||
#[derive(StructOpt, Debug)]
|
||||
pub enum ToMillauMessage {
|
||||
/// Make an on-chain remark (comment).
|
||||
Remark,
|
||||
/// Transfer the specified `amount` of native tokens to a particular `recipient`.
|
||||
Transfer {
|
||||
#[structopt(long)]
|
||||
recipient: bp_millau::AccountId,
|
||||
#[structopt(long)]
|
||||
amount: bp_millau::Balance,
|
||||
},
|
||||
}
|
||||
|
||||
arg_enum! {
|
||||
#[derive(Debug)]
|
||||
/// The origin to use when dispatching the message on the target chain.
|
||||
pub enum Origins {
|
||||
Root,
|
||||
Target,
|
||||
Source,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user