Skip to content

Commit b893bbd

Browse files
authored
Merge pull request #267 from AdExNetwork/issue-266-long-cmd-arguments
Issue #266 long cmd arguments
2 parents fb0ec9b + bbeb83d commit b893bbd

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

primitives/src/util/tests/prep_db.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
use crate::{
2+
channel::{Pricing, PricingBounds},
23
BigNum, Channel, ChannelId, ChannelSpec, EventSubmission, SpecValidators, ValidatorDesc,
34
ValidatorId,
45
};
@@ -69,7 +70,7 @@ lazy_static! {
6970
title: None,
7071
validators: SpecValidators::new(DUMMY_VALIDATOR_LEADER.clone(), DUMMY_VALIDATOR_FOLLOWER.clone()),
7172
max_per_impression: 10.into(),
72-
min_per_impression: 10.into(),
73+
min_per_impression: 1.into(),
7374
targeting: vec![],
7475
min_targeting_score: None,
7576
event_submission: Some(EventSubmission { allow: vec![] }),
@@ -79,7 +80,7 @@ lazy_static! {
7980
nonce: Some(nonce),
8081
withdraw_period_start: Utc.timestamp_millis(4_073_414_400_000),
8182
ad_units: vec![],
82-
pricing_bounds: None,
83+
pricing_bounds: Some(PricingBounds {impression: None, click: Some(Pricing { max: 0.into(), min: 0.into()})}),
8384
},
8485
}
8586
};

sentry/src/main.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
2828
)
2929
.arg(
3030
Arg::with_name("adapter")
31+
.long("adapter")
3132
.short("a")
3233
.help("the adapter for authentication and signing")
3334
.required(true)
@@ -37,18 +38,21 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
3738
)
3839
.arg(
3940
Arg::with_name("keystoreFile")
41+
.long("keystoreFile")
4042
.short("k")
4143
.help("path to the JSON Ethereum Keystore file")
4244
.takes_value(true),
4345
)
4446
.arg(
4547
Arg::with_name("dummyIdentity")
48+
.long("dummyIdentity")
4649
.short("i")
4750
.help("the identity to use with the dummy adapter")
4851
.takes_value(true),
4952
)
5053
.arg(
5154
Arg::with_name("clustered")
55+
.long("clustered")
5256
.short("c")
5357
.help("Run app in cluster mode with multiple workers"),
5458
)

validator_worker/src/main.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ fn main() -> Result<(), Box<dyn Error>> {
3636
)
3737
.arg(
3838
Arg::with_name("adapter")
39+
.long("adapter")
3940
.short("a")
4041
.help("the adapter for authentication and signing")
4142
.required(true)
@@ -45,18 +46,21 @@ fn main() -> Result<(), Box<dyn Error>> {
4546
)
4647
.arg(
4748
Arg::with_name("keystoreFile")
49+
.long("keystoreFile")
4850
.short("k")
4951
.help("path to the JSON Ethereum Keystore file")
5052
.takes_value(true),
5153
)
5254
.arg(
5355
Arg::with_name("dummyIdentity")
56+
.long("dummyIdentity")
5457
.short("i")
5558
.help("the identity to use with the dummy adapter")
5659
.takes_value(true),
5760
)
5861
.arg(
5962
Arg::with_name("sentryUrl")
63+
.long("sentryUrl")
6064
.short("u")
6165
.help("the URL to the sentry used for listing channels")
6266
.default_value("http://127.0.0.1:8005")
@@ -65,6 +69,7 @@ fn main() -> Result<(), Box<dyn Error>> {
6569
)
6670
.arg(
6771
Arg::with_name("singleTick")
72+
.long("singleTick")
6873
.short("t")
6974
.takes_value(false)
7075
.help("runs the validator in single-tick mode and exit"),

0 commit comments

Comments
 (0)