Skip to content

Fix: Add --provider Option to CLI Commands#15

Open
salmanabdurrahman wants to merge 1 commit intozakirkun:mainfrom
salmanabdurrahman:fix/add-provider-option-cli-commands
Open

Fix: Add --provider Option to CLI Commands#15
salmanabdurrahman wants to merge 1 commit intozakirkun:mainfrom
salmanabdurrahman:fix/add-provider-option-cli-commands

Conversation

@salmanabdurrahman
Copy link

Summary

This PR adds the --provider (-p) option to:

  • guardian workflow
  • guardian recon
  • guardian scan

Users can now override the AI provider directly from the command line without editing guardian.yaml.

Fixes #13

Changes

  • Added --provider / -p flag
  • Provider validation (gemini, openai, claude, openrouter)
  • Clear error message for invalid providers
  • Fully backward compatible (works without the flag)

Files updated:

  • workflow.py
  • recon.py
  • scan.py
    Total: 3 files, +56 insertions

Example Usage

guardian workflow run --name recon --target example.com --provider gemini
guardian recon --domain example.com --provider claude
guardian scan --target 192.168.1.1 --provider openai

Testing

  • Option appears in help text
  • Provider validation works
  • Override functions correctly
  • No breaking changes

This keeps consistency with the existing --model option and improves usability.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

provider option not available

1 participant

Comments