Skip to content

feat: watch mode with config#4

Open
sidnz wants to merge 3 commits intoHelixar-AI:developfrom
sidnz:feat/watch-mode-clean
Open

feat: watch mode with config#4
sidnz wants to merge 3 commits intoHelixar-AI:developfrom
sidnz:feat/watch-mode-clean

Conversation

@sidnz
Copy link
Copy Markdown
Contributor

@sidnz sidnz commented Mar 11, 2026

This pull request introduces a new "watch" command to the Sentinel CLI, enabling continuous monitoring of targets with periodic scans and change detection. The implementation includes the command itself, updates to the documentation, and comprehensive integration tests to ensure correct behavior under various scenarios.

New Watch Command Functionality:

  • Added a watch command to the CLI, allowing users to continuously monitor configuration files, endpoints, or containers, with options for scan interval, output format, change detection, and safe mode. The command handles graceful shutdown via SIGINT and supports reporting only on changes. (sentinel/cli.py)

Documentation Updates:

  • Updated the CLI documentation to reflect the new fifth command (watch) and described its usage and options in the README.md file, including examples. (README.md) [1] [2]
  • Updated the CLI docstring to mention the new "watch" command. (sentinel/cli.py)

Testing Enhancements:

  • Added a comprehensive test class for the watch command, including fixtures to simulate single and multiple scan cycles, tests for output correctness, change detection, and output file writing. (tests/integration/test_cli.py)
  • Included necessary imports for patching and signal handling in the test suite. (tests/integration/test_cli.py)

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.

1 participant