mirror of
https://github.com/TECHNOFAB11/pay-respects.git
synced 2025-12-12 14:30:10 +01:00
chore: cleanup
This commit is contained in:
parent
f9b8ee44f2
commit
49dcbea59e
2 changed files with 11 additions and 12 deletions
|
|
@ -28,6 +28,12 @@ async fn main() -> Result<(), std::io::Error> {
|
|||
if std::env::var("_PR_AI_DISABLE").is_ok() {
|
||||
return Ok(());
|
||||
}
|
||||
let mode = std::env::var("_PR_MODE");
|
||||
if let Ok(mode) = mode {
|
||||
if mode.as_str() == "noconfirm" {
|
||||
return Ok(());
|
||||
}
|
||||
}
|
||||
|
||||
let locale = {
|
||||
let sys_locale = get_locale().unwrap_or("en-US".to_string());
|
||||
|
|
@ -39,13 +45,6 @@ async fn main() -> Result<(), std::io::Error> {
|
|||
};
|
||||
rust_i18n::set_locale(&locale[0..2]);
|
||||
|
||||
let mode = std::env::var("_PR_MODE");
|
||||
if let Ok(mode) = mode {
|
||||
if mode.as_str() == "noconfirm" {
|
||||
return Ok(());
|
||||
}
|
||||
}
|
||||
|
||||
let command = std::env::var("_PR_LAST_COMMAND").expect("_PR_LAST_COMMAND not set");
|
||||
let error = std::env::var("_PR_ERROR_MSG").expect("_PR_ERROR_MSG not set");
|
||||
colored::control::set_override(true);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue