pub async fn execute_show(
_args: &ConfigShowArgs,
output: &Output,
root: &Path,
config_path: Option<&Path>,
) -> Result<()>Expand description
Execute the config show command.
Displays the current configuration loaded from the workspace, including all changeset, version, and registry settings. If no configuration file exists, displays the default configuration.
§Arguments
_args- Command arguments (currently unused but reserved for future options)output- Output handler for formatting command resultsroot- Workspace root directoryconfig_path- Optional path to config file (from global--configoption)
§Returns
Returns Ok(()) on success, or an error if configuration cannot be loaded.
§Errors
Returns an error if:
- The configuration file exists but is invalid
- File system operations fail
- Serialization to JSON fails (in JSON output mode)
§Examples
ⓘ
use sublime_cli_tools::commands::config::execute_show;
use sublime_cli_tools::cli::commands::ConfigShowArgs;
use sublime_cli_tools::output::{Output, OutputFormat};
use std::path::Path;
let args = ConfigShowArgs {};
let output = Output::new(OutputFormat::Human, std::io::stdout(), false);
execute_show(&args, &output, Path::new("."), None).await?;