Modernize dependencies, add wishlist features, improve error handling
- Remove once_cell and serde dependencies; use std::sync::LazyLock and manual serde_json::Value parsing instead - Add wishlist support: load wishlist from my_cars.json, prefix missing cars with '+' in missing mode, add 'wishlist' command to show stale wishlist entries (prefixed with '-') - Replace unwrap()/expect() with graceful eprintln warnings and early returns throughout (get_car_list, parse_car_times, etc.) - Scope all Mutex locks tightly to avoid holding during I/O (print_best_times, print_best_cars, print_trash, print_wishlist_stale) - Replace custom split_prefix_postfix with str::split_once - Pass owned-car set into parse_all_times/parse_car_times via Arc<HashSet> instead of reading file per task - Consolidate my_cars.json loading into single load_my_cars_data() returning both owned and wishlist sets - Add .gitignore and Cargo.lock to version control - Report task failures in parse_all_times join loop
This commit is contained in:
parent
32c4d3c10e
commit
6a68469239
4 changed files with 2374 additions and 168 deletions
6
.gitignore
vendored
Normal file
6
.gitignore
vendored
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
/target
|
||||
.idea/
|
||||
my_cars.json
|
||||
cars_repo.json
|
||||
tracks_repo.json
|
||||
times/
|
||||
Loading…
Add table
Add a link
Reference in a new issue