Skip to content

Commit 1506e90

Browse files
committed
sugondat-shim: introduce a common env for port
1 parent cf0de03 commit 1506e90

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

sugondat-shim/src/cli.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ struct Cli {
1111
command: Commands,
1212
}
1313

14+
/// The environment variable used to override the default port to listen to when serving or to
15+
/// connect to when running RPCs.
16+
const SUGONDAT_SHIM_PORT_ENV: &str = "SUGONDAT_SHIM_PORT";
17+
1418
/// Common parameters for the adapter subcommands.
1519
///
1620
/// It's not declared on the `Cli` struct with `clap(flatten)` because of how the syntax
@@ -25,7 +29,7 @@ pub struct AdapterServerParams {
2529
#[clap(
2630
short,
2731
long,
28-
env = "SUGONDAT_SHIM_PORT",
32+
env = SUGONDAT_SHIM_PORT_ENV,
2933
default_value = "10995",
3034
group = "listen"
3135
)]

0 commit comments

Comments
 (0)