home / skills / shotaiuchi / dotclaude / wf0-config

wf0-config skill

/dotclaude/skills/wf0-config

This skill helps you interactively configure .wf/config.json by selecting categories, adjusting branches, worktrees, commits, verification, and Jira settings.

npx playbooks add skill shotaiuchi/dotclaude --skill wf0-config

Review the files below or copy the command above to add this skill to your agents.

Files (1)
SKILL.md
2.8 KB
---
name: wf0-config
description: .wf/config.json の対話式設定エディタ
argument-hint: "[show | init | <category>]"
---

**Always respond in Japanese.**

# /wf0-config

Interactively edit `.wf/config.json` settings.

## Usage

```
/wf0-config                  # Interactive mode (category selection)
/wf0-config show             # Display current settings
/wf0-config init             # Initialize config.json
/wf0-config <category>       # Edit specific category
```

## Categories

| Category | Key Settings |
|----------|-------------|
| `branch` | `default_base_branch`, `base_branch_candidates`, `allow_pattern_candidates`, `branch_prefix` |
| `worktree` | `worktree.enabled`, `worktree.root_dir` |
| `commit` | `commit.type_detection`, `commit.default_type` |
| `verify` | `verify.test`, `verify.build`, `verify.lint` |
| `jira` | `jira.project`, `jira.domain` |

## Processing

### `show`

Display all settings formatted. Show "(not set)" with default hints for unconfigured values.

### `init`

1. If config exists, ask to overwrite (AskUserQuestion)
2. Ask required settings: default base branch, enable worktree
3. Create config.json

### Interactive mode (no arguments)

1. **Category selection**: AskUserQuestion with multiSelect=true listing all 5 categories
2. **Edit each selected category**: Ask about individual settings using AskUserQuestion for each

### `<category>`

Skip category selection, directly edit the specified category.

### Category Dialogs

Each category presents AskUserQuestion prompts for its settings. Current values shown when available.

- **Branch**: base branch (develop/main/master/Other), candidates, prefix config, allow patterns
- **Worktree**: enable/disable, root directory (.worktrees/Other)
- **Commit**: type detection (auto/manual/fixed), default type (feat/fix/chore/refactor)
- **Verify**: test/build/lint commands (npm/yarn/pnpm/Other for each)
- **Jira**: project key, domain

### Save

1. Show summary of changes (old→new)
2. Ask confirmation (AskUserQuestion: Save/Cancel)
3. Write to `.wf/config.json`

## Config Schema

```json
{
  "default_base_branch": "develop",
  "base_branch_candidates": ["develop", "main", "master"],
  "allow_pattern_candidates": ["release/.*", "hotfix/.*"],
  "branch_prefix": { "FEAT": "feat", "FIX": "fix", "REFACTOR": "refactor", "CHORE": "chore", "RFC": "rfc" },
  "worktree": { "enabled": false, "root_dir": ".worktrees" },
  "commit": { "type_detection": "auto", "default_type": "feat" },
  "verify": { "test": "npm test", "build": "npm run build", "lint": "npm run lint" },
  "jira": { "project": null, "domain": null }
}
```

## Notes

- `show` without config: suggest `/wf0-config init`
- `<category>` without config: error, suggest `init` first
- No arguments without config: auto-enter `init` flow
- Preserve unedited settings

Overview

This skill provides an interactive editor for the .wf/config.json file. It guides you through initializing, viewing, and editing configuration categories like branch, worktree, commit, verify, and jira. The tool preserves existing settings and shows clear summaries before saving changes. It supports both a guided multi-category flow and direct category edits.

How this skill works

The skill reads .wf/config.json when present and presents AskUserQuestion-style prompts for each configuration field. Commands include show (formatted display), init (create or overwrite with prompts), interactive mode (multi-select categories), and direct category editing. Changes are summarized (old → new) and written only after confirmation, and unedited keys are preserved.

When to use it

  • Set up repository workflow configuration for the first time with init.
  • Quickly inspect current .wf/config.json values using show.
  • Adjust only specific areas (branch, worktree, commit, verify, jira) without manual JSON editing.
  • Update CI/test/build commands or commit type detection across projects.
  • Enforce branch naming conventions and branch prefix mapping for teams.

Best practices

  • Run /wf0-config show before making changes to understand current state.
  • Use init only when creating or intentionally overwriting configuration; follow prompts carefully.
  • Edit one category at a time for focused changes and easier review of the summary.
  • Keep branch_prefix and base_branch_candidates consistent with your branching policy.
  • Provide explicit values for jira.project and jira.domain only if you use Jira integrations.

Example use cases

  • Initialize a new repository workflow by running /wf0-config init and answering base branch and worktree prompts.
  • View effective configuration with /wf0-config show to see defaults and (not set) hints.
  • Enable worktrees and set a custom root directory via /wf0-config worktree.
  • Adjust commit type detection from auto to manual for teams that prefer explicit commit types using /wf0-config commit.
  • Update verify commands to use pnpm or yarn for specific projects using /wf0-config verify.

FAQ

What happens if .wf/config.json is missing and I run /wf0-config without args?

The skill auto-enters the init flow to create a new config and will prompt for required settings.

Will unedited settings be lost when I save changes?

No. The editor preserves any keys you do not edit and only updates values you confirm in the summary step.