pub mod completion;
pub mod cwd_file;
mod exec;
pub mod init;
pub use completion::run_completion;
pub use exec::{escape_shell_arg, exec, exec_async, exec_silent};
pub fn get_gwm_bin_expr() -> String {
match std::env::current_exe() {
Ok(path) => match path.to_str() {
Some(s) => escape_shell_arg(s),
None => {
eprintln!("Warning: gwm path contains non-UTF8 characters, falling back to 'gwm'");
"'gwm'".to_string()
}
},
Err(e) => {
eprintln!(
"Warning: Could not determine gwm binary path ({}), falling back to 'gwm'",
e
);
"'gwm'".to_string()
}
}
}