Skip to main content

Module cli

Module cli 

Source
Expand description

§CLI Module

This module defines the command-line interface for RepoLens using clap.

§Commands

CommandDescription
initInitialize a new configuration file
planAnalyze repository and show planned actions
applyApply planned changes to the repository
reportGenerate an audit report
compareCompare two audit reports
schemaDisplay JSON Schema for report output
install-hooksInstall or remove Git hooks

§Submodules

  • commands - Command implementations
  • exit_codes - Standardized exit codes
  • output - Report output formatters (JSON, Markdown, SARIF, Terminal)

§Global Options

All commands support these global options:

  • -v, --verbose - Increase verbosity level (use multiple times: -v, -vv, -vvv)
  • -c, --config <FILE> - Path to configuration file
  • -C, --directory <DIR> - Working directory (defaults to current directory)

§Examples

# Initialize configuration
repolens init --preset opensource

# Run audit and show plan
repolens plan

# Generate JSON report
repolens report --format json -o report.json

# Apply fixes
repolens apply --yes

Modules§

commands
CLI commands module
exit_codes
Exit codes for the CLI
output
Output formatting module for CLI

Structs§

Cli
RepoLens - Audit and prepare repositories for open source or enterprise standards

Enums§

Commands