Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions bin/pcl/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ const VERSION_MESSAGE: &str = concat!(
env!("VERGEN_GIT_SHA"),
"\nBuild Timestamp: ",
env!("VERGEN_BUILD_TIMESTAMP"),
"\nDefault DA URL: ",
pcl_core::default_da_url!(),
);

#[derive(Parser)]
Expand Down
13 changes: 12 additions & 1 deletion crates/core/src/assertion_da.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,16 @@ use crate::{
error::DaSubmitError,
};

/// Macro that defines the default DA URL - can be used in concat! macros
#[macro_export]
macro_rules! default_da_url {
() => {
"https://demo-21-assertion-da.phylax.systems"
};
}

pub const DEFAULT_DA_URL: &str = default_da_url!();

/// Command-line arguments for storing assertions in the Data Availability layer.
///
/// This struct handles the configuration needed to submit assertions to the DA layer,
Expand All @@ -53,7 +63,7 @@ pub struct DaStoreArgs {
short = 'u',
env = "PCL_DA_URL",
value_hint = ValueHint::Url,
default_value = "https://demo-21-assertion-da.phylax.systems"
default_value = DEFAULT_DA_URL
)]
pub url: String,

Expand Down Expand Up @@ -125,6 +135,7 @@ impl DaStoreArgs {
println!("\n\n{}", "Assertion Information".bold().green());
println!("{}", "===================".green());
println!("{assertion}");
println!("\nSubmitted to assertion DA: {}", self.url);

println!("\n{}", "Next Steps:".bold());
println!("Submit this assertion to a project with:");
Expand Down
Loading