diff options
| author | lukeflo | 2025-10-10 10:31:45 +0200 |
|---|---|---|
| committer | lukeflo | 2025-10-10 10:31:45 +0200 |
| commit | f9548af5c7693edf536b4ad45564a964338e2c2e (patch) | |
| tree | ec7b093c48fc06cff9c651d0f59baa57d2fcb898 /src/main.rs | |
| parent | 669936a8e4ff99012e8b32ae15616f8fe206ab2d (diff) | |
| download | bibiman-f9548af5c7693edf536b4ad45564a964338e2c2e.tar.gz bibiman-f9548af5c7693edf536b4ad45564a964338e2c2e.zip | |
set up citekey formatting cli, reformat help output
Diffstat (limited to 'src/main.rs')
| -rw-r--r-- | src/main.rs | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/main.rs b/src/main.rs index 58805d5..e735eb0 100644 --- a/src/main.rs +++ b/src/main.rs @@ -18,7 +18,6 @@ use app::App; use cliargs::CLIArgs; use color_eyre::eyre::Result; -use config::BibiConfig; use errorsetup::init_error_hooks; pub mod app; @@ -31,13 +30,16 @@ pub mod tui; #[tokio::main] async fn main() -> Result<()> { // Parse CLI arguments - let (mut parsed_args, mut cfg) = CLIArgs::parse_args()?; + let (mut parsed_args, mut cfg, run_tui) = CLIArgs::parse_args()?; - init_error_hooks()?; + if run_tui { + init_error_hooks()?; - // Create an application. - let mut app = App::new(&mut parsed_args, &mut cfg)?; + // Create an application. + let mut app = App::new(&mut parsed_args, &mut cfg)?; + + app.run(&cfg).await?; + } - app.run(&cfg).await?; Ok(()) } |
