mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-03-18 01:51:20 -07:00
feat(sdd): rename to SDD and migrate storage to .gemini/specs
- Renamed built-in extension 'Conductor' to 'Spec-Driven Development (SDD)'. - Updated commands from '/conductor:<action>' to '/spec <action>'. - Migrated default artifact storage from 'conductor/' to '.gemini/specs/'. - Updated documentation, security policies, and internal references. - Refactored FileCommandLoader to use standardized variable hydration. - Replaced automatic Conductor deletion with a non-destructive migration prompt. - Added step in setup to ensure .gemini/specs/ is exempted from .gitignore.
This commit is contained in:
@@ -371,7 +371,7 @@ your approval. It is ideal for quick exploration and ad-hoc tasks.
|
||||
|
||||
[Spec-Driven Development (SDD)] is a built-in methodology for managing large
|
||||
features and complex tasks through persistent artifacts. It organizes work into
|
||||
tracks and stores them in your project's `conductor/` directory.
|
||||
tracks and stores them in your project's `.gemini/specs/` directory.
|
||||
|
||||
SDD leverages Plan Mode internally to ensure architectural safety during the
|
||||
design phase. To get started with SDD, run `/spec setup`.
|
||||
@@ -387,12 +387,12 @@ design phase. To get started with SDD, run `/spec setup`.
|
||||
|
||||
### Comparison of planning workflows
|
||||
|
||||
| Feature | Standard | SDD |
|
||||
| :-------------- | :--------------------------------- | :------------------------------------------------ |
|
||||
| **Persistence** | Ephemeral, session-based | Persistent, stored in your repository |
|
||||
| **Workflow** | Lightweight research & design | Structured Spec -> Plan -> Implement lifecycle |
|
||||
| **Artifacts** | `.md` files in a temp directory | `spec.md`, `plan.md`, `tracks.md` in `conductor/` |
|
||||
| **Best For** | Quick exploration and ad-hoc tasks | Major features, bug fixes, and long-running tasks |
|
||||
| Feature | Standard | SDD |
|
||||
| :-------------- | :--------------------------------- | :---------------------------------------------------- |
|
||||
| **Persistence** | Ephemeral, session-based | Persistent, stored in your repository |
|
||||
| **Workflow** | Lightweight research & design | Structured Spec -> Plan -> Implement lifecycle |
|
||||
| **Artifacts** | `.md` files in a temp directory | `spec.md`, `plan.md`, `tracks.md` in `.gemini/specs/` |
|
||||
| **Best For** | Quick exploration and ad-hoc tasks | Major features, bug fixes, and long-running tasks |
|
||||
|
||||
### Build your own
|
||||
|
||||
|
||||
@@ -58,12 +58,12 @@ features by you or anyone on your team.
|
||||
|
||||
**Generated Artifacts:**
|
||||
|
||||
- `conductor/product.md`
|
||||
- `conductor/product-guidelines.md`
|
||||
- `conductor/tech-stack.md`
|
||||
- `conductor/workflow.md`
|
||||
- `conductor/code_styleguides/`
|
||||
- `conductor/tracks.md`
|
||||
- `.gemini/specs/product.md`
|
||||
- `.gemini/specs/product-guidelines.md`
|
||||
- `.gemini/specs/tech-stack.md`
|
||||
- `.gemini/specs/workflow.md`
|
||||
- `.gemini/specs/code_styleguides/`
|
||||
- `.gemini/specs/tracks.md`
|
||||
|
||||
```bash
|
||||
/spec setup
|
||||
@@ -81,9 +81,9 @@ critical artifacts:
|
||||
|
||||
**Generated Artifacts:**
|
||||
|
||||
- `conductor/tracks/<track_id>/spec.md`
|
||||
- `conductor/tracks/<track_id>/plan.md`
|
||||
- `conductor/tracks/<track_id>/metadata.json`
|
||||
- `.gemini/specs/tracks/<track_id>/spec.md`
|
||||
- `.gemini/specs/tracks/<track_id>/plan.md`
|
||||
- `.gemini/specs/tracks/<track_id>/metadata.json`
|
||||
|
||||
```bash
|
||||
/spec create
|
||||
@@ -98,8 +98,8 @@ through the `plan.md` file, checking off tasks as it completes them.
|
||||
|
||||
**Updated Artifacts:**
|
||||
|
||||
- `conductor/tracks.md` (Status updates)
|
||||
- `conductor/tracks/<track_id>/plan.md` (Status updates)
|
||||
- `.gemini/specs/tracks.md` (Status updates)
|
||||
- `.gemini/specs/tracks/<track_id>/plan.md` (Status updates)
|
||||
- Project context files (Synchronized on completion)
|
||||
|
||||
```bash
|
||||
@@ -134,14 +134,14 @@ During implementation, you can also:
|
||||
|
||||
## Commands Reference
|
||||
|
||||
| Command | Description | Artifacts |
|
||||
| :---------------- | :-------------------------------------------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `/spec setup` | Scaffolds the project and sets up the SDD environment. Run this once per project. | `conductor/product.md`<br>`conductor/product-guidelines.md`<br>`conductor/tech-stack.md`<br>`conductor/workflow.md`<br>`conductor/tracks.md` |
|
||||
| `/spec create` | Starts a new feature or bug track. Generates `spec.md` and `plan.md`. | `conductor/tracks/<id>/spec.md`<br>`conductor/tracks/<id>/plan.md`<br>`conductor/tracks.md` |
|
||||
| `/spec implement` | Executes the tasks defined in the current track's plan. | `conductor/tracks.md`<br>`conductor/tracks/<id>/plan.md` |
|
||||
| `/spec status` | Displays the current progress of the tracks file and active tracks. | Reads `conductor/tracks.md` |
|
||||
| `/spec revert` | Reverts a track, phase, or task by analyzing git history. | Reverts git history |
|
||||
| `/spec review` | Reviews completed work against guidelines and the plan. | Reads `plan.md`, `product-guidelines.md` |
|
||||
| Command | Description | Artifacts |
|
||||
| :---------------- | :-------------------------------------------------------------------------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `/spec setup` | Scaffolds the project and sets up the SDD environment. Run this once per project. | `.gemini/specs/product.md`<br>`.gemini/specs/product-guidelines.md`<br>`.gemini/specs/tech-stack.md`<br>`.gemini/specs/workflow.md`<br>`.gemini/specs/tracks.md` |
|
||||
| `/spec create` | Starts a new feature or bug track. Generates `spec.md` and `plan.md`. | `.gemini/specs/tracks/<id>/spec.md`<br>`.gemini/specs/tracks/<id>/plan.md`<br>`.gemini/specs/tracks.md` |
|
||||
| `/spec implement` | Executes the tasks defined in the current track's plan. | `.gemini/specs/tracks.md`<br>`.gemini/specs/tracks/<id>/plan.md` |
|
||||
| `/spec status` | Displays the current progress of the tracks file and active tracks. | Reads `.gemini/specs/tracks.md` |
|
||||
| `/spec revert` | Reverts a track, phase, or task by analyzing git history. | Reverts git history |
|
||||
| `/spec review` | Reviews completed work against guidelines and the plan. | Reads `plan.md`, `product-guidelines.md` |
|
||||
|
||||
[Conductor]:
|
||||
https://developers.googleblog.com/conductor-introducing-context-driven-development-for-gemini-cli/
|
||||
|
||||
@@ -699,7 +699,7 @@ Would you like to attempt to install via "git clone" instead?`,
|
||||
(e) => e.name === 'conductor',
|
||||
);
|
||||
if (conductorIdx !== -1) {
|
||||
const message = `The "conductor" extension has been renamed to "sdd" and is now built-in. Please run "gemini extensions uninstall conductor" to migrate. Your project files in "conductor/" will be preserved.`;
|
||||
const message = `The "conductor" extension has been renamed to "sdd" and is now built-in. Please run "gemini extensions uninstall conductor" to migrate. Your project files in ".gemini/specs/" will be preserved.`;
|
||||
debugLogger.warn(message);
|
||||
coreEvents.emitFeedback('warning', message);
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ You are an AI agent assistant for the Spec-Driven Development (SDD) framework. Y
|
||||
|
||||
CRITICAL: You must validate the success of every tool call. If any tool call fails, you MUST halt the current operation immediately, announce the failure to the user, and await further instructions.
|
||||
|
||||
PLAN MODE PROTOCOL: Parts of this process run within Plan Mode. While in Plan Mode, you are explicitly permitted and required to use `write_file`, `replace`, and authorized `run_shell_command` calls to create and modify files within the `conductor/` directory. **CRITICAL: You MUST use relative paths starting with `conductor/` (e.g., `conductor/product.md`) for all file operations. Do NOT use absolute paths, as they will be blocked by Plan Mode security policies. REDIRECTION (e.g., `>` or `>>`) is strictly NOT allowed in `run_shell_command` calls while in Plan Mode and will cause tool failure.**
|
||||
PLAN MODE PROTOCOL: Parts of this process run within Plan Mode. While in Plan Mode, you are explicitly permitted and required to use `write_file`, `replace`, and authorized `run_shell_command` calls to create and modify files within the `.gemini/specs/` directory. **CRITICAL: You MUST use relative paths starting with `.gemini/specs/` (e.g., `.gemini/specs/product.md`) for all file operations. Do NOT use absolute paths, as they will be blocked by Plan Mode security policies. REDIRECTION (e.g., `>` or `>>`) is strictly NOT allowed in `run_shell_command` calls while in Plan Mode and will cause tool failure.**
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -186,7 +186,7 @@ CRITICAL: You must validate the success of every tool call. If any tool call fai
|
||||
- **multiSelect:** false
|
||||
- **options:**
|
||||
- Label: "Review", Description: "Run the review command to verify changes before finalizing."
|
||||
- Label: "Archive", Description: "Move the track's folder to `conductor/archive/` and remove it from the tracks file."
|
||||
- Label: "Archive", Description: "Move the track's folder to `.gemini/specs/archive/` and remove it from the tracks file."
|
||||
- Label: "Delete", Description: "Permanently delete the track's folder and remove it from the tracks file."
|
||||
- Label: "Skip", Description: "Do nothing and leave it in the tracks file."
|
||||
|
||||
@@ -194,10 +194,10 @@ CRITICAL: You must validate the success of every tool call. If any tool call fai
|
||||
* **If user chooses "Review":**
|
||||
* Announce: "Please run `/spec review` to verify your changes. You will be able to archive or delete the track after the review."
|
||||
* **If user chooses "Archive":**
|
||||
i. **Create Archive Directory:** Check for the existence of `conductor/archive/`. If it does not exist, create it.
|
||||
ii. **Archive Track Folder:** Move the track's folder from its current location (resolved via the **Tracks Directory**) to `conductor/archive/<track_id>`.
|
||||
i. **Create Archive Directory:** Check for the existence of `.gemini/specs/archive/`. If it does not exist, create it.
|
||||
ii. **Archive Track Folder:** Move the track's folder from its current location (resolved via the **Tracks Directory**) to `.gemini/specs/archive/<track_id>`.
|
||||
iii. **Remove from Tracks File:** Read the content of the **Tracks Registry** file, remove the entire section for the completed track (the part that starts with `---` and contains the track description), and write the modified content back to the file.
|
||||
iv. **Commit Changes:** Stage the **Tracks Registry** file and `conductor/archive/`. Commit with the message `chore(conductor): Archive track '<track_description>'`.
|
||||
iv. **Commit Changes:** Stage the **Tracks Registry** file and `.gemini/specs/archive/`. Commit with the message `chore(conductor): Archive track '<track_description>'`.
|
||||
v. **Announce Success:** Announce: "Track '<track_description>' has been successfully archived."
|
||||
* **If user chooses "Delete":**
|
||||
i. **CRITICAL WARNING:** Before proceeding, immediately call the `ask_user` tool to ask for final confirmation (do not repeat the warning in the chat):
|
||||
|
||||
@@ -61,7 +61,7 @@ CRITICAL: You must validate the success of every tool call. If any tool call fai
|
||||
### 2.2 Retrieve Context
|
||||
1. **Load Project Context:**
|
||||
- Read `product-guidelines.md` and `tech-stack.md`.
|
||||
- **CRITICAL:** Check for the existence of `conductor/code_styleguides/` directory.
|
||||
- **CRITICAL:** Check for the existence of `.gemini/specs/code_styleguides/` directory.
|
||||
- If it exists, list and read ALL `.md` files within it. These are the **Law**. Violations here are **High** severity.
|
||||
2. **Load Track Context (if reviewing a track):**
|
||||
- Read the track's `plan.md`.
|
||||
@@ -92,7 +92,7 @@ CRITICAL: You must validate the success of every tool call. If any tool call fai
|
||||
1. **Intent Verification:** Does the code actually implement what the `plan.md` (and `spec.md` if available) asked for?
|
||||
2. **Style Compliance:**
|
||||
- Does it follow `product-guidelines.md`?
|
||||
- Does it strictly follow `conductor/code_styleguides/*.md`?
|
||||
- Does it strictly follow `.gemini/specs/code_styleguides/*.md`?
|
||||
3. **Correctness & Safety:**
|
||||
- Look for bugs, race conditions, null pointer risks.
|
||||
- **Security Scan:** Check for hardcoded secrets, PII leaks, or unsafe input handling.
|
||||
@@ -210,14 +210,14 @@ CRITICAL: You must validate the success of every tool call. If any tool call fai
|
||||
- **type:** "choice"
|
||||
- **multiSelect:** false
|
||||
- **options:**
|
||||
- Label: "Archive", Description: "Move the track's folder to `conductor/archive/` and remove it from the tracks file."
|
||||
- Label: "Archive", Description: "Move the track's folder to `.gemini/specs/archive/` and remove it from the tracks file."
|
||||
- Label: "Delete", Description: "Permanently delete the track's folder and remove it from the tracks file."
|
||||
- Label: "Skip", Description: "Do nothing and leave it in the tracks file."
|
||||
|
||||
3. **Handle User Response:**
|
||||
* **If "Archive":**
|
||||
i. **Setup:** Ensure `conductor/archive/` exists.
|
||||
ii. **Move:** Move track folder to `conductor/archive/<track_id>`.
|
||||
i. **Setup:** Ensure `.gemini/specs/archive/` exists.
|
||||
ii. **Move:** Move track folder to `.gemini/specs/archive/<track_id>`.
|
||||
iii. **Update Registry:** Remove track section from **Tracks Registry**.
|
||||
iv. **Commit:** Stage registry and archive. Commit: `chore(conductor): Archive track '<track_name>'`.
|
||||
v. **Announce:** "Track '<track_name>' archived."
|
||||
|
||||
@@ -5,7 +5,7 @@ You are an AI agent. Your primary function is to set up and manage a software pr
|
||||
|
||||
CRITICAL: You must validate the success of every tool call. If a tool call fails (e.g., due to a policy restriction or path error), you should attempt to intelligently self-correct by reviewing the error message. If the failure is unrecoverable after a self-correction attempt, you MUST halt the current operation immediately, announce the failure to the user, and await further instructions.
|
||||
|
||||
PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in Plan Mode, you are explicitly permitted and required to use `write_file`, `replace`, and authorized `run_shell_command` calls to create and modify files within the `conductor/` directory. **CRITICAL: You MUST use relative paths starting with `conductor/` (e.g., `conductor/product.md`) for all file operations. Do NOT use absolute paths, as they will be blocked by Plan Mode security policies. REDIRECTION (e.g., `>` or `>>`) is strictly NOT allowed in `run_shell_command` calls while in Plan Mode and will cause tool failure.** Do not defer these actions to a final execution phase; execute them immediately as each step is completed and approved by the user.
|
||||
PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in Plan Mode, you are explicitly permitted and required to use `write_file`, `replace`, and authorized `run_shell_command` calls to create and modify files within the `.gemini/specs/` directory. **CRITICAL: You MUST use relative paths starting with `.gemini/specs/` (e.g., `.gemini/specs/product.md`) for all file operations. Do NOT use absolute paths, as they will be blocked by Plan Mode security policies. REDIRECTION (e.g., `>` or `>>`) is strictly NOT allowed in `run_shell_command` calls while in Plan Mode and will cause tool failure.** Do not defer these actions to a final execution phase; execute them immediately as each step is completed and approved by the user.
|
||||
---
|
||||
|
||||
## 1.1 PRE-INITIALIZATION OVERVIEW
|
||||
@@ -28,7 +28,7 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
|
||||
2. **Announce Audit:** Inform the user that you are auditing the project for any existing SDD configuration.
|
||||
|
||||
3. **Audit Artifacts:** Check the file system for the existence of the following files/directories in the `conductor/` directory:
|
||||
3. **Audit Artifacts:** Check the file system for the existence of the following files/directories in the `.gemini/specs/` directory:
|
||||
- `product.md`
|
||||
- `product-guidelines.md`
|
||||
- `tech-stack.md`
|
||||
@@ -64,12 +64,12 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
- **Brownfield Indicators:**
|
||||
- Check for dependency manifests: `package.json`, `pom.xml`, `requirements.txt`, `go.mod`, `Cargo.toml`.
|
||||
- Check for source code directories: `src/`, `app/`, `lib/`, `bin/` containing code files.
|
||||
- If a `.git` directory exists, execute `git status --porcelain`. Ignore changes within the `conductor/` directory. If there are *other* uncommitted changes, it may be Brownfield.
|
||||
- If a `.git` directory exists, execute `git status --porcelain`. Ignore changes within the `.gemini/specs/` directory. If there are *other* uncommitted changes, it may be Brownfield.
|
||||
- If ANY of the primary indicators (manifests or source code directories) are found, classify as **Brownfield**.
|
||||
- **Greenfield Condition:**
|
||||
- Classify as **Greenfield** ONLY if:
|
||||
1. NONE of the "Brownfield Indicators" are found.
|
||||
2. The directory contains no application source code or dependency manifests (ignoring the `conductor/` directory, a clean or newly initialized `.git` folder, and a `README.md`).
|
||||
2. The directory contains no application source code or dependency manifests (ignoring the `.gemini/specs/` directory, a clean or newly initialized `.git` folder, and a `README.md`).
|
||||
|
||||
|
||||
2. **Resume Fast-Forward Check:**
|
||||
@@ -128,8 +128,8 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
- **placeholder:** "e.g., A mobile app for tracking expenses"
|
||||
- **CRITICAL: You MUST NOT execute any tool calls until the user has provided a response.**
|
||||
- **Upon receiving the user's response:**
|
||||
- Execute `mkdir -p conductor`.
|
||||
- Write the user's response into `conductor/product.md` under a header named `# Initial Concept`.
|
||||
- Execute `mkdir -p .gemini/specs`.
|
||||
- Write the user's response into `.gemini/specs/product.md` under a header named `# Initial Concept`.
|
||||
|
||||
6. **Continue:** Immediately proceed to the next section.
|
||||
|
||||
@@ -177,7 +177,7 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
- **options:**
|
||||
- Label: "Approve", Description: "The guide looks good, proceed to the next step."
|
||||
- Label: "Suggest changes", Description: "I want to modify the drafted content."
|
||||
6. **Write File:** Once approved, append the generated content to the existing `conductor/product.md` file, preserving the `# Initial Concept` section.
|
||||
6. **Write File:** Once approved, append the generated content to the existing `.gemini/specs/product.md` file, preserving the `# Initial Concept` section.
|
||||
7. **Continue:** Immediately proceed to the next section.
|
||||
|
||||
### 2.2 Generate Product Guidelines (Interactive)
|
||||
@@ -224,7 +224,7 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
- **options:**
|
||||
- Label: "Approve", Description: "The guidelines look good, proceed to the next step."
|
||||
- Label: "Suggest changes", Description: "I want to modify the drafted content."
|
||||
6. **Write File:** Once approved, write the generated content to the `conductor/product-guidelines.md` file.
|
||||
6. **Write File:** Once approved, write the generated content to the `.gemini/specs/product-guidelines.md` file.
|
||||
7. **Continue:** Immediately proceed to the next section.
|
||||
|
||||
### 2.3 Generate Tech Stack (Interactive)
|
||||
@@ -279,7 +279,7 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
- **options:**
|
||||
- Label: "Approve", Description: "The tech stack looks good, proceed to the next step."
|
||||
- Label: "Suggest changes", Description: "I want to modify the drafted content."
|
||||
6. **Write File:** Once approved, write the generated content to the `conductor/tech-stack.md` file.
|
||||
6. **Write File:** Once approved, write the generated content to the `.gemini/specs/tech-stack.md` file.
|
||||
7. **Continue:** Immediately proceed to the next section.
|
||||
|
||||
### 2.4 Select Guides (Interactive)
|
||||
@@ -322,12 +322,12 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
- **Action:** Announce "I'll present the additional guides. Please select all that apply." Then, immediately call the `ask_user` tool (do not list the questions in the chat).
|
||||
- **Method:** Use a single `ask_user` tool call. Dynamically split the available guides into batches of 4 options max. Create one `multiSelect: true` question for each batch.
|
||||
|
||||
3. **Action:** Construct and execute a command to create the directory and copy all selected files. For example: `mkdir -p conductor/code_styleguides && cp ${extensionPath}/templates/code_styleguides/python.md ${extensionPath}/templates/code_styleguides/javascript.md conductor/code_styleguides/`
|
||||
3. **Action:** Construct and execute a command to create the directory and copy all selected files. For example: `mkdir -p .gemini/specs/code_styleguides && cp ${extensionPath}/templates/code_styleguides/python.md ${extensionPath}/templates/code_styleguides/javascript.md .gemini/specs/code_styleguides/`
|
||||
4. **Continue:** Immediately proceed to the next section.
|
||||
|
||||
### 2.5 Select Workflow (Interactive)
|
||||
1. **Copy Initial Workflow:**
|
||||
- Copy `${extensionPath}/templates/workflow.md` to `conductor/workflow.md`.
|
||||
- Copy `${extensionPath}/templates/workflow.md` to `.gemini/specs/workflow.md`.
|
||||
2. **Determine Mode:** Use the `ask_user` tool to let the user choose their preferred workflow.
|
||||
- **questions:**
|
||||
- **header:** "Workflow"
|
||||
@@ -368,12 +368,12 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
|
||||
Is there anything else you'd like to change or add to the workflow? (Leave blank to finish or type your additional requirements).
|
||||
|
||||
4. **Action:** Update `conductor/workflow.md` based on all user answers from both steps.
|
||||
4. **Action:** Update `.gemini/specs/workflow.md` based on all user answers from both steps.
|
||||
|
||||
|
||||
### 2.6 Finalization
|
||||
1. **Generate Index File:**
|
||||
- Create `conductor/index.md` with the following content:
|
||||
- Create `.gemini/specs/index.md` with the following content:
|
||||
```markdown
|
||||
# Project Context
|
||||
|
||||
@@ -390,7 +390,7 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
- [Tracks Registry](./tracks.md)
|
||||
- [Tracks Directory](./tracks/)
|
||||
```
|
||||
- **Announce:** "Created `conductor/index.md` to serve as the project context index."
|
||||
- **Announce:** "Created `.gemini/specs/index.md` to serve as the project context index."
|
||||
|
||||
2. **Summarize Actions:** Present a summary of all actions taken during the initial setup, including:
|
||||
- The guide files that were copied.
|
||||
@@ -402,11 +402,11 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
## 3.0 INITIAL PLAN AND TRACK GENERATION
|
||||
**PROTOCOL: Interactively define project requirements, propose a single track, and then automatically create the corresponding track and its phased plan.**
|
||||
|
||||
**Pre-Requisite (Cleanup):** If you are resuming this section because a previous setup was interrupted, check if the `conductor/tracks/` directory exists but is incomplete. If it exists, **delete** the entire `conductor/tracks/` directory before proceeding to ensure a clean slate for the new track generation.
|
||||
**Pre-Requisite (Cleanup):** If you are resuming this section because a previous setup was interrupted, check if the `.gemini/specs/tracks/` directory exists but is incomplete. If it exists, **delete** the entire `.gemini/specs/tracks/` directory before proceeding to ensure a clean slate for the new track generation.
|
||||
|
||||
### 3.1 Generate Product Requirements (Interactive)(For greenfield projects only)
|
||||
1. **Transition to Requirements:** Announce that the initial project setup is complete. State that you will now begin defining the high-level product requirements by asking about topics like user stories and functional/non-functional requirements.
|
||||
2. **Analyze Context:** Read and analyze the content of `conductor/product.md` to understand the project's core concept.
|
||||
2. **Analyze Context:** Read and analyze the content of `.gemini/specs/product.md` to understand the project's core concept.
|
||||
3. **Determine Mode:** Use the `ask_user` tool to let the user choose their preferred workflow.
|
||||
- **questions:**
|
||||
- **header:** "Product Reqs"
|
||||
@@ -472,7 +472,7 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
|
||||
### 3.3 Convert the Initial Track into Artifacts (Automated)
|
||||
1. **State Your Goal:** Once the track is approved, announce that you will now create the artifacts for this initial track.
|
||||
2. **Initialize Tracks File:** Create the `conductor/tracks.md` file with the initial header and the first track:
|
||||
2. **Initialize Tracks File:** Create the `.gemini/specs/tracks.md` file with the initial header and the first track:
|
||||
```markdown
|
||||
# Project Tracks
|
||||
|
||||
@@ -489,11 +489,11 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
b. **Generate Track-Specific Spec & Plan:**
|
||||
i. Automatically generate a detailed `spec.md` for this track.
|
||||
ii. Automatically generate a `plan.md` for this track.
|
||||
- **CRITICAL:** The structure of the tasks must adhere to the principles outlined in the workflow file at `conductor/workflow.md`. For example, if the workflow specificies Test-Driven Development, each feature task must be broken down into a "Write Tests" sub-task followed by an "Implement Feature" sub-task.
|
||||
- **CRITICAL:** The structure of the tasks must adhere to the principles outlined in the workflow file at `.gemini/specs/workflow.md`. For example, if the workflow specificies Test-Driven Development, each feature task must be broken down into a "Write Tests" sub-task followed by an "Implement Feature" sub-task.
|
||||
- **CRITICAL:** Include status markers `[ ]` for **EVERY** task and sub-task. The format must be:
|
||||
- Parent Task: `- [ ] Task: ...`
|
||||
- Sub-task: ` - [ ] ...`
|
||||
- **CRITICAL: Inject Phase Completion Tasks.** You MUST read the `conductor/workflow.md` file to determine if a "Phase Completion Verification and Checkpointing Protocol" is defined. If this protocol exists, then for each **Phase** that you generate in `plan.md`, you MUST append a final meta-task to that phase. The format for this meta-task is: `- [ ] Task: SDD - User Manual Verification '<Phase Name>' (Protocol in workflow.md)`. You MUST replace `<Phase Name>` with the actual name of the phase.
|
||||
- **CRITICAL: Inject Phase Completion Tasks.** You MUST read the `.gemini/specs/workflow.md` file to determine if a "Phase Completion Verification and Checkpointing Protocol" is defined. If this protocol exists, then for each **Phase** that you generate in `plan.md`, you MUST append a final meta-task to that phase. The format for this meta-task is: `- [ ] Task: SDD - User Manual Verification '<Phase Name>' (Protocol in workflow.md)`. You MUST replace `<Phase Name>` with the actual name of the phase.
|
||||
c. **Create Track Artifacts:**
|
||||
i. **Generate and Store Track ID:** Create a unique Track ID from the track description using format `shortname_YYYYMMDD` and store it. You MUST use this exact same ID for all subsequent steps for this track.
|
||||
ii. **Create Single Directory:** Resolve the **Tracks Directory** via the **Universal File Resolution Protocol** and create a single new directory: `<Tracks Directory>/<track_id>/`.
|
||||
@@ -526,6 +526,9 @@ PLAN MODE PROTOCOL: This setup process runs entirely within Plan Mode. While in
|
||||
|
||||
### 3.4 Final Announcement
|
||||
1. **Announce Completion:** After the track has been created, announce that the project setup and initial track generation are complete.
|
||||
1.5 **Ensure Artifact Visibility:** If a `.gitignore` file exists in the project root:
|
||||
- Check if it contains a rule that might ignore the `.gemini/specs/` directory (e.g., `.gemini/`).
|
||||
- To ensure these artifacts are always shared with the team, append `!.gemini/specs/` to the end of the `.gitignore` file if it is not already explicitly exempted.
|
||||
2. **Save SDD Files:** Add and commit all files with the commit message `conductor(setup): Add conductor setup files`.
|
||||
3. **Next Steps:** Inform the user that they can now begin work by running `/spec implement`.
|
||||
"""
|
||||
@@ -2,6 +2,6 @@
|
||||
"name": "sdd",
|
||||
"contextFileName": "GEMINI.md",
|
||||
"plan": {
|
||||
"directory": "conductor"
|
||||
"directory": ".gemini/specs"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,9 +4,9 @@ toolName = ["write_file", "replace"]
|
||||
priority = 100 # prioritize over other extension policies
|
||||
decision = "ask_user"
|
||||
modes = ["plan"]
|
||||
argsPattern = '"(?:file_path|path)":"conductor/[^"]*"'
|
||||
argsPattern = '"(?:file_path|path)":"\.gemini/specs/[^"]*"'
|
||||
|
||||
# Allow tools used by SDD to set up conductor dir
|
||||
# Allow tools used by SDD to set up specs dir
|
||||
[[rule]]
|
||||
toolName = "run_shell_command"
|
||||
commandPrefix = ["git status", "git diff", "ls", "mkdir", "cp", "git init", "git add", "git commit"]
|
||||
Reference in New Issue
Block a user