Commit 5161639
committed
refactor: comprehensive codebase improvements for v2.8.0
- Extract CheckOptions struct with clap::Args to eliminate parameter explosion
- Split cmd_check (310 lines) into 5 focused functions
- Split scanner.rs (1148 lines) into scanner/{mod,report,network}.rs
- Create shared lockfile/platform.rs to unify duplicated platform parsing
- Encapsulate parser state into SourceState struct with methods
- Migrate deprecated serde_yaml to serde_yml
- Fix Database::open().unwrap() panic with proper error propagation
- Extract check_staleness/build_ignore_comments to src/check.rs for testability
- Replace .ok() with io::Result<()> in format output (text.rs, json.rs)
- Handle broken pipe gracefully in CLI output
- Add tempfile crate for reliable test cleanup
- Add Clone derive to FixSuggestion
- Add 13 new unit tests (307 → 320)1 parent 11a9554 commit 5161639
19 files changed
Lines changed: 1454 additions & 1353 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
| 17 | + | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
1 | 6 | | |
2 | 7 | | |
3 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
464 | 464 | | |
465 | 465 | | |
466 | 466 | | |
467 | | - | |
| 467 | + | |
468 | 468 | | |
469 | | - | |
| 469 | + | |
470 | 470 | | |
471 | 471 | | |
472 | 472 | | |
| |||
480 | 480 | | |
481 | 481 | | |
482 | 482 | | |
483 | | - | |
484 | | - | |
485 | 483 | | |
486 | 484 | | |
487 | 485 | | |
| |||
505 | 503 | | |
506 | 504 | | |
507 | 505 | | |
508 | | - | |
| 506 | + | |
509 | 507 | | |
510 | | - | |
511 | | - | |
512 | | - | |
| 508 | + | |
| 509 | + | |
513 | 510 | | |
514 | 511 | | |
515 | 512 | | |
516 | 513 | | |
517 | 514 | | |
518 | 515 | | |
519 | | - | |
| 516 | + | |
520 | 517 | | |
521 | 518 | | |
522 | 519 | | |
523 | 520 | | |
524 | 521 | | |
525 | 522 | | |
526 | | - | |
527 | | - | |
| 523 | + | |
| 524 | + | |
528 | 525 | | |
529 | | - | |
530 | | - | |
| 526 | + | |
531 | 527 | | |
532 | 528 | | |
533 | 529 | | |
534 | 530 | | |
535 | 531 | | |
536 | 532 | | |
537 | | - | |
538 | | - | |
| 533 | + | |
| 534 | + | |
539 | 535 | | |
540 | | - | |
541 | | - | |
| 536 | + | |
542 | 537 | | |
543 | 538 | | |
544 | 539 | | |
545 | 540 | | |
546 | 541 | | |
547 | 542 | | |
548 | | - | |
549 | | - | |
| 543 | + | |
| 544 | + | |
550 | 545 | | |
551 | 546 | | |
552 | 547 | | |
553 | | - | |
554 | 548 | | |
555 | 549 | | |
556 | 550 | | |
557 | 551 | | |
558 | | - | |
559 | | - | |
| 552 | + | |
| 553 | + | |
560 | 554 | | |
561 | | - | |
562 | 555 | | |
563 | 556 | | |
564 | 557 | | |
| |||
613 | 606 | | |
614 | 607 | | |
615 | 608 | | |
616 | | - | |
617 | | - | |
| 609 | + | |
| 610 | + | |
618 | 611 | | |
619 | 612 | | |
620 | | - | |
621 | 613 | | |
622 | 614 | | |
623 | 615 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
114 | | - | |
| 114 | + | |
115 | 115 | | |
116 | 116 | | |
117 | 117 | | |
| |||
133 | 133 | | |
134 | 134 | | |
135 | 135 | | |
136 | | - | |
| 136 | + | |
137 | 137 | | |
138 | 138 | | |
139 | 139 | | |
| |||
511 | 511 | | |
512 | 512 | | |
513 | 513 | | |
514 | | - | |
| 514 | + | |
515 | 515 | | |
516 | 516 | | |
517 | 517 | | |
| |||
0 commit comments