Commit graph

8 commits

Author SHA1 Message Date
Snider
8dacc91593
feat(/core:deps): show module dependencies (#82)
This commit introduces a new command, `/core:deps`, to visualize dependencies between modules in the monorepo.

The command parses a `repos.yaml` file to build a dependency graph and supports the following functionalities:
- Displaying a full dependency tree for all modules.
- Displaying a dependency tree for a single module.
- Displaying reverse dependencies for a single module using the `--reverse` flag.
- Detecting and reporting circular dependencies.

The implementation consists of a Python script that handles the core logic and a command definition file that connects the command to the script. A comprehensive test suite is included to ensure the correctness of the implementation.

Co-authored-by: Claude <noreply@anthropic.com>
2026-02-02 07:19:58 +00:00
Snider
0f15a1fdfd
feat(core): add /core:log command for smart log viewing (#77)
Implements a new `/core:log` command to provide smart log viewing with filtering and analysis capabilities.

This new command allows users to:
- Tail `laravel.log` in real-time.
- Filter log entries by error level (`--errors`).
- Filter log entries by a specific time range (`--since`).
- Filter log entries using a regular expression (`--grep`).
- Filter log entries by a specific request ID (`--request`).
- Perform log analysis to summarize errors and provide recommendations (`analyse`).

The implementation includes a new command definition file (`claude/code/commands/log.md`) and a corresponding shell script (`claude/code/scripts/log.sh`) that contains the core logic for the command. A dummy log file (`storage/logs/laravel.log`) has also been added to facilitate testing and development.
2026-02-02 07:17:59 +00:00
Snider
be32fec23d
feat(plugin): Implement workspace awareness to detect the current module (#75)
Introduces a new script to detect the current module (PHP or Go) based on the presence of composer.json or go.mod files, git remote URL, or the current directory name.

This context is loaded once per session and used to dynamically adjust commands, starting with the QA command.

Refactors the QA command and verification scripts to use the new module context, removing redundant project-type detection.
2026-02-02 07:17:36 +00:00
Snider
c9391635eb
feat(code): implement /core:commit smart commit command (#73)
Implements a new `/core:commit` command that analyzes staged changes to generate a conventional commit message.

The command supports three main modes of operation:
- `/core:commit`: Automatically generates a commit message based on the content of the staged files.
- `/core:commit "custom message"`: Uses the provided string as the full commit message.
- `/core:commit --amend`: Amends the last commit with the new message.

Message generation includes several heuristics:
- **Commit Type:** Determined by file paths (e.g., `_test.go` -> `test`) and diff content (e.g., keywords like `fix` or `refactor`).
- **Scope:** Inferred from the most common directory name among the staged files.
- **Summary:** Extracted from function or class names in the diff, or defaults to a file-based summary.
- **Co-Author:** A `Co-Authored-By` trailer is automatically appended.

This feature streamlines the development workflow by automating the creation of descriptive and conventional commit messages.
2026-02-02 07:16:29 +00:00
Snider
dc4a5ed329
feat(core): Add /core:status command for multi-repo status (#72)
Adds a new command `/core:status` to display the status of all repositories in a formatted table.

The command provides the following features:
- Displays module name, branch, clean/dirty status, and ahead/behind counts.
- Supports filtering for dirty repositories with the `--dirty` flag.
- Supports filtering for repositories behind remote with the `--behind` flag.
- Includes a summary line with counts of dirty, behind, and clean repositories.

This is implemented by wrapping the existing `core dev health` command with a new script that handles formatting and filtering.
2026-02-02 07:15:08 +00:00
Snider
94d9d28f4a
feat: Add /core:env for environment management (#70)
This commit introduces a new command, `/core:env`, to manage environment variables. It provides a set of tools to compare and manage a local `.env` file against a `.env.example` template, with a strong emphasis on security by masking sensitive values.

The command includes the following subcommands:
- `/core:env`: Shows the current environment variables with sensitive values masked.
- `/core:env check`: Validates the local `.env` file against `.env.example`, reporting any missing or required variables.
- `/core:env diff`: Displays the differences between the `.env` and `.env.example` files, ensuring sensitive data is not exposed.
- `/core:env sync`: Adds missing variables from `.env.example` to the local `.env` file without overwriting existing values.

To prevent accidental exposure of secrets, the `.env` file is now included in `.gitignore`.
2026-02-02 07:14:37 +00:00
Snider
14cb0f4d7b
feat(code): add secret detection hook (#67)
This change introduces a new hook that runs before a file is written or edited. The hook executes a script that scans the file content for patterns that match common secret formats, such as API keys, AWS keys, and private keys.

If a potential secret is found, the script exits with a non-zero status code, which blocks the file operation and prevents the secret from being committed. The script also provides a user-friendly error message with the filename, line number, and a suggestion to use environment variables.

This helps to prevent accidental commits of sensitive credentials to the repository.
2026-02-02 07:13:28 +00:00
Snider
9942ab8081 refactor: restructure as plugin monorepo
Reorganise as a marketplace with multiple focused plugins:
- claude/code: Core development (hooks, scripts, data collection)
- claude/review: Code review automation
- claude/verify: Work verification
- claude/qa: Quality assurance loops
- claude/ci: CI/CD integration

Structure:
- .claude-plugin/marketplace.json lists all plugins
- Each plugin has its own .claude-plugin/plugin.json
- Commands namespaced: /code:*, /review:*, /qa:*, etc.

Install individual plugins or all via marketplace:
  claude plugin add host-uk/core-agent
  claude plugin add host-uk/core-agent/claude/code

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-01 19:44:26 +00:00