Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,7 @@ fizzy migrate board BOARD_ID --from SOURCE_ACCOUNT --to TARGET_ACCOUNT --include

### Skill Installation

Install the Fizzy skill file for use with AI coding assistants like Claude Code or OpenCode.
Install the Fizzy skill file for use with AI coding assistants like Codex, Claude Code, or OpenCode.

```bash
fizzy skill
Expand All @@ -436,6 +436,7 @@ This interactive command lets you choose where to install the SKILL.md file:
| Claude Code (Project) | `.claude/skills/fizzy/SKILL.md` |
| OpenCode (Global) | `~/.config/opencode/skill/fizzy/SKILL.md` |
| OpenCode (Project) | `.opencode/skill/fizzy/SKILL.md` |
| Codex (Global) | `~/.codex/skills/fizzy/SKILL.md` (or `$CODEX_HOME/skills/fizzy/SKILL.md`) |
| Other | Custom path of your choice |

The skill file enables AI assistants to understand and use Fizzy CLI commands effectively.
Expand Down
15 changes: 14 additions & 1 deletion internal/commands/skill.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,17 @@ var skillLocations = []SkillLocation{
Path: ".opencode/skill/fizzy/SKILL.md",
Description: "Available only in this project",
},
{
Name: "Codex (Global)",
Path: codexGlobalSkillPath(),
Description: "Available in all Codex projects",
},
}

var skillCmd = &cobra.Command{
Use: "skill",
Short: "Install Fizzy skill file",
Long: "Install the Fizzy SKILL.md file for use with Claude Code or OpenCode.",
Long: "Install the Fizzy SKILL.md file for use with Codex, Claude Code, or OpenCode.",
Run: runSkill,
}

Expand Down Expand Up @@ -172,6 +177,14 @@ func normalizeSkillPath(path string) string {
return filepath.Join(path, "fizzy", skillFilename)
}

func codexGlobalSkillPath() string {
codexHome := strings.TrimSpace(os.Getenv("CODEX_HOME"))
if codexHome == "" {
return "~/.codex/skills/fizzy/SKILL.md"
}
return filepath.Join(codexHome, "skills", "fizzy", skillFilename)
}

// expandPath expands ~ to home directory (works on both Unix and Windows)
func expandPath(path string) string {
// Handle both ~/path (Unix) and ~\path (Windows)
Expand Down