Skip to content

Commit 3c1b29c

Browse files
authored
Merge pull request #10376 from Byron/fix
Restore the previous 'CHANNEL' functionality
2 parents 12807ea + f205136 commit 3c1b29c

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

crates/but-testing/src/main.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,14 @@ async fn main() -> Result<()> {
2121
trace::init()?;
2222
}
2323
let _op_span = tracing::info_span!("cli-op").entered();
24+
static CHANNEL: Option<&str> = option_env!("CHANNEL");
25+
if let Some(suffix) = &args.app_suffix
26+
&& CHANNEL != Some(suffix)
27+
{
28+
bail!(
29+
"Launch with CHANNEL={suffix} cargo run -- but-testing… instead - must be compiled in!"
30+
)
31+
}
2432

2533
match &args.cmd {
2634
args::Subcommands::AddProject {

0 commit comments

Comments
 (0)