diff options
author | Joris | 2023-07-15 10:09:30 +0200 |
---|---|---|
committer | Joris | 2023-07-15 10:09:30 +0200 |
commit | 8fb457d5639d11d5075d664001e98148e223f257 (patch) | |
tree | fd8b2b1ddcd5fa0756ff8ecabb34f66031e0fc5b /src/main.rs | |
parent | d68ef3c63c041fcf1844df1fffddbc9c8cf1bfcf (diff) |
Re synchronize deck if necessary between cards
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs index ddc6edc..b18cb1a 100644 --- a/src/main.rs +++ b/src/main.rs @@ -29,10 +29,18 @@ fn main() -> Result<()> { let deck_name = deck::pp_from_path(&deck_path).unwrap_or_else(|| "Deck".to_string()); sync::run(&mut conn, &deck_path)?; + let deck_last_sync = util::time::seconds_since_unix_epoch()?; let mut term = gui::setup_terminal()?; - match gui::start(&conn, &mut term, &deck_name, args.hide_remaining) { + match gui::start( + &mut conn, + &mut term, + &deck_path, + &deck_name, + deck_last_sync, + args.hide_remaining, + ) { Ok(()) => (), Err(msg) => { // Show errors in TUI, otherwise they are hidden |