[go: up one dir, main page]

Module clap_localization

Module clap_localization 

Source
Expand description

Helper clap functions to localize error handling and options

This module provides utilities for handling clap errors with localization support. It uses clap’s error context API to extract structured information from errors instead of parsing error strings, providing a more robust solution.

Structs§

ErrorFormatter
Unified error formatter that handles all error types consistently

Enums§

Color
Color enum for consistent styling

Functions§

configure_localized_command
Configures a clap Command with proper localization and color settings.
handle_clap_error_with_exit_code
Handles a clap error directly with a custom exit code.
handle_clap_result
Handles clap command parsing results with proper localization support.
handle_clap_result_with_exit_code
Handles clap command parsing with a custom exit code for errors.