-
Notifications
You must be signed in to change notification settings - Fork 3.5k
feat(cli): enhance /init command to create custom slash command #7888
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Update the /init slash command prompt to also create a custom "review" slash command file at .continue/rules/review.md with invokable frontmatter and review-focused instructions. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 issue found across 1 file
Prompt for AI agents (all 1 issues)
Understand the root cause of the following 1 issues and fix them.
<file name="extensions/cli/src/commands/init.ts">
<violation number="1" location="extensions/cli/src/commands/init.ts:47">
Claim that /review will be invokable is likely incorrect without setting a name; default name becomes rules/review.md. Clarify instruction or set name in frontmatter.</violation>
</file>
React with 👍 or 👎 to teach cubic. Mention @cubic-dev-ai
to give feedback, ask questions, or re-run the review.
Provide specific, actionable feedback for improvements. | ||
\`\`\` | ||
This slash command will be invokable using /review and will provide instructions for code review tasks common to this repository. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Claim that /review will be invokable is likely incorrect without setting a name; default name becomes rules/review.md. Clarify instruction or set name in frontmatter.
Prompt for AI agents
Address the following comment on extensions/cli/src/commands/init.ts at line 47:
<comment>Claim that /review will be invokable is likely incorrect without setting a name; default name becomes rules/review.md. Clarify instruction or set name in frontmatter.</comment>
<file context>
@@ -30,7 +30,23 @@ Create an AGENTS.md file with the following structure:
+Provide specific, actionable feedback for improvements.
+\`\`\`
+
+This slash command will be invokable using /review and will provide instructions for code review tasks common to this repository.
+
+Please create both the AGENTS.md file and the .continue/rules/review.md file using the Write tool after analyzing the repository. Focus on providing actionable information that would help both AI agents and human developers understand and work effectively with this codebase. Keep the files concise but informational.`;
</file context>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of a hardcoded string/filepath instructions we should use the same logic that we have in core/tools/implementations/createRuleBlock.ts
Otherwise this will almost certainly break at some point in the future
Summary
/init
slash command prompt to instruct the model to create a custom slash command file.continue/rules/review.md
with proper frontmatter structureChanges
extensions/cli/src/commands/init.ts
to include instructions for creating a slash command fileinvokable: true
in the frontmatterTest Plan
/init
command in the CLIAGENTS.md
and.continue/rules/review.md
files are created/review
command becomes available after file creation🤖 Generated with Claude Code
Summary by cubic
Enhanced /init to also scaffold a /review slash command by generating .continue/rules/review.md with invokable frontmatter, alongside AGENTS.md. This makes a ready-to-use code review command available right after initialization.