Skip to content

Commit

Permalink
chore(antctl): use PeersArg::local instead of a separate arg
Browse files Browse the repository at this point in the history
  • Loading branch information
RolandSherwin committed Dec 6, 2024
1 parent 56865c6 commit 469e496
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
6 changes: 3 additions & 3 deletions ant-bootstrap/src/initial_peers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ pub struct PeersArgs {
///
/// If this argument is used, any others will be ignored because they do not apply to the first
/// node.
#[clap(long)]
#[clap(long, default_value = "false")]
pub first: bool,
/// Addr(s) to use for bootstrap, in a 'multiaddr' format containing the peer ID.
///
Expand Down Expand Up @@ -54,7 +54,7 @@ pub struct PeersArgs {
/// Set to indicate this is a local network. You could also set the `local` feature flag to set this to true.
///
/// This would use mDNS for peer discovery.
#[clap(long, conflicts_with = "network_contacts_url")]
#[clap(long, conflicts_with = "network_contacts_url", default_value = "false")]
pub local: bool,
/// Set to indicate this is a testnet.
///
Expand All @@ -63,7 +63,7 @@ pub struct PeersArgs {
pub disable_mainnet_contacts: bool,

/// Set to not load the bootstrap addresses from the local cache.
#[clap(long)]
#[clap(long, default_value = "false")]
pub ignore_cache: bool,
}
impl PeersArgs {
Expand Down
8 changes: 1 addition & 7 deletions ant-node-manager/src/bin/cli/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -131,11 +131,6 @@ pub enum SubCmd {
/// This enables the use of antnode services from a home network with a router.
#[clap(long)]
home_network: bool,
/// Set this flag to launch antnode with the --local flag.
///
/// This is useful for building a service-based local network.
#[clap(long)]
local: bool,
/// Provide the path for the log directory for the installed node.
///
/// This path is a prefix. Each installed node will have its own directory underneath it.
Expand Down Expand Up @@ -1075,7 +1070,6 @@ async fn main() -> Result<()> {
env_variables,
evm_network,
home_network,
local,
log_dir_path,
log_format,
max_archived_log_files,
Expand Down Expand Up @@ -1103,7 +1097,7 @@ async fn main() -> Result<()> {
env_variables,
Some(evm_network.try_into()?),
home_network,
local,
peers.local,
log_dir_path,
log_format,
max_archived_log_files,
Expand Down

0 comments on commit 469e496

Please sign in to comment.