File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -285,6 +285,11 @@ fn run_default(store: &Store) -> Result<()> {
285285 ) ;
286286 }
287287
288+ // Update Notification (4h cache)
289+ if let Some ( latest) = crate :: guard:: update:: check ( ) {
290+ crate :: guard:: update:: print_notification ( & latest) ;
291+ }
292+
288293 println ! ( ) ;
289294 Ok ( ( ) )
290295}
Original file line number Diff line number Diff line change @@ -32,10 +32,10 @@ pub fn get_status() -> Status {
3232 . unwrap_or_default ( )
3333 . as_secs ( ) ;
3434
35- // Try to get latest version from cache or fetch it
35+ // Try to get latest version from cache or fetch it (Cache: 4 hours)
3636 let latest = if let Ok ( content) = fs:: read_to_string ( & cache_path)
3737 && let Ok ( cache) = serde_json:: from_str :: < UpdateCache > ( & content)
38- && now < cache. last_checked + 86400
38+ && now < cache. last_checked + 14400
3939 {
4040 Some ( cache. latest_version )
4141 } else {
You can’t perform that action at this time.
0 commit comments