Fix all clippy warnings and migrate CLI to clap #1

Open
delandtj wants to merge 1 commit from clippy-fixes-and-clap into main
Member
  • Fix 40+ clippy warnings across the codebase:

    • collapsible_if: Use if-let chains with && for cleaner nested conditionals
    • manual_strip: Use strip_prefix() instead of starts_with() + slicing
    • io_other_error: Use std::io::Error::other()
    • inherent_to_string: Implement Display trait for FilePermissions
    • unnecessary_lazy_evaluations: Use unwrap_or instead of unwrap_or_else
    • redundant_closure: Use tuple variant directly in map_err
    • type_complexity: Add CheckinRow type alias
    • unnecessary_unwrap: Use pattern matching
    • needless_borrow: Remove unnecessary references
    • while_let_on_iterator: Use for loop
    • redundant_allocation: Fix Arc<Arc<...>> in WebDAV server
    • derivable_impls: Use #[derive(Default)] with #[default] attribute
    • manual_inspect: Use inspect_err instead of map_err
    • ptr_arg: Use &Path instead of &PathBuf in function signatures
  • Migrate CLI argument parsing from hand-rolled to clap:

    • Add clap dependency with derive feature
    • Define Cli struct with proper argument definitions
    • Add Commands enum for start/stop/status subcommands
    • Auto-generated --help and --version
    • Type-safe argument parsing with validation

Passes cargo clippy --all-targets --all-features with zero warnings.

- Fix 40+ clippy warnings across the codebase: - collapsible_if: Use if-let chains with && for cleaner nested conditionals - manual_strip: Use strip_prefix() instead of starts_with() + slicing - io_other_error: Use std::io::Error::other() - inherent_to_string: Implement Display trait for FilePermissions - unnecessary_lazy_evaluations: Use unwrap_or instead of unwrap_or_else - redundant_closure: Use tuple variant directly in map_err - type_complexity: Add CheckinRow type alias - unnecessary_unwrap: Use pattern matching - needless_borrow: Remove unnecessary references - while_let_on_iterator: Use for loop - redundant_allocation: Fix Arc<Arc<...>> in WebDAV server - derivable_impls: Use #[derive(Default)] with #[default] attribute - manual_inspect: Use inspect_err instead of map_err - ptr_arg: Use &Path instead of &PathBuf in function signatures - Migrate CLI argument parsing from hand-rolled to clap: - Add clap dependency with derive feature - Define Cli struct with proper argument definitions - Add Commands enum for start/stop/status subcommands - Auto-generated --help and --version - Type-safe argument parsing with validation Passes cargo clippy --all-targets --all-features with zero warnings.
- Fix 40+ clippy warnings across the codebase:
  - collapsible_if: Use if-let chains with && for cleaner nested conditionals
  - manual_strip: Use strip_prefix() instead of starts_with() + slicing
  - io_other_error: Use std::io::Error::other()
  - inherent_to_string: Implement Display trait for FilePermissions
  - unnecessary_lazy_evaluations: Use unwrap_or instead of unwrap_or_else
  - redundant_closure: Use tuple variant directly in map_err
  - type_complexity: Add CheckinRow type alias
  - unnecessary_unwrap: Use pattern matching
  - needless_borrow: Remove unnecessary references
  - while_let_on_iterator: Use for loop
  - redundant_allocation: Fix Arc<Arc<...>> in WebDAV server
  - derivable_impls: Use #[derive(Default)] with #[default] attribute
  - manual_inspect: Use inspect_err instead of map_err
  - ptr_arg: Use &Path instead of &PathBuf in function signatures

- Migrate CLI argument parsing from hand-rolled to clap:
  - Add clap dependency with derive feature
  - Define Cli struct with proper argument definitions
  - Add Commands enum for start/stop/status subcommands
  - Auto-generated --help and --version
  - Type-safe argument parsing with validation

Passes cargo clippy --all-targets --all-features with zero warnings.
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin clippy-fixes-and-clap:clippy-fixes-and-clap
git switch clippy-fixes-and-clap

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch main
git merge --no-ff clippy-fixes-and-clap
git switch clippy-fixes-and-clap
git rebase main
git switch main
git merge --ff-only clippy-fixes-and-clap
git switch clippy-fixes-and-clap
git rebase main
git switch main
git merge --no-ff clippy-fixes-and-clap
git switch main
git merge --squash clippy-fixes-and-clap
git switch main
git merge --ff-only clippy-fixes-and-clap
git switch main
git merge clippy-fixes-and-clap
git push origin main
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lhumina_research/heroforge!1
No description provided.