charmbracelet
Charmbraceletのエコシステムを活用し、Bubble Teaなどのライブラリを用いて、洗練されたGo言語のターミナルUIやインタラクティブなCLIアプリケーションを構築・デザインするSkill。
📜 元の英語説明(参考)
Build Go terminal user interfaces and interactive CLIs with the Charmbracelet ecosystem, especially Bubble Tea, Bubbles, Huh, Lip Gloss, Wish, Glamour, and Log. Use this skill when the user asks for a TUI, terminal UI, interactive CLI, Bubble Tea model/update/view code, Bubbles widgets, Huh forms, Lip Gloss layout or styling, Wish SSH apps, Glamour markdown rendering, or a polished Go terminal app.
🇯🇵 日本人クリエイター向け解説
Charmbraceletのエコシステムを活用し、Bubble Teaなどのライブラリを用いて、洗練されたGo言語のターミナルUIやインタラクティブなCLIアプリケーションを構築・デザインするSkill。
※ jpskill.com 編集部が日本のビジネス現場向けに補足した解説です。Skill本体の挙動とは独立した参考情報です。
下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o charmbracelet.zip https://jpskill.com/download/8670.zip && unzip -o charmbracelet.zip && rm charmbracelet.zip
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/8670.zip -OutFile "$d\charmbracelet.zip"; Expand-Archive "$d\charmbracelet.zip" -DestinationPath $d -Force; ri "$d\charmbracelet.zip"
完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。
💾 手動でダウンロードしたい(コマンドが難しい人向け)
- 1. 下の青いボタンを押して
charmbracelet.zipをダウンロード - 2. ZIPファイルをダブルクリックで解凍 →
charmbraceletフォルダができる - 3. そのフォルダを
C:\Users\あなたの名前\.claude\skills\(Win)または~/.claude/skills/(Mac)へ移動 - 4. Claude Code を再起動
⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。
🎯 このSkillでできること
下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。
📦 インストール方法 (3ステップ)
- 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
- 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
- 3. 展開してできたフォルダを、ホームフォルダの
.claude/skills/に置く- · macOS / Linux:
~/.claude/skills/ - · Windows:
%USERPROFILE%\.claude\skills\
- · macOS / Linux:
Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。
詳しい使い方ガイドを見る →- 最終更新
- 2026-05-18
- 取得日時
- 2026-05-18
- 同梱ファイル
- 1
📖 Skill本文(日本語訳)
※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。
[Skill 名] charmbracelet
このスキルを使用すると、Charmbracelet スタックで最新の Go CLI を構築できます。ステートフルな TUI またはインタラクティブなターミナルフローには、デフォルトで Bubble Tea を使用し、必要に応じて Bubbles、Huh、Lip Gloss、Wish、Glamour、Log を重ねて使用します。
まずはこちらから
- 現在の v2 エコシステムでは、
charm.land/.../v2インポートを使用してください。 - Bubble Tea をアプリのランタイムおよびステートマシンとして扱ってください。
- Bubbles をアプリのシェルではなく、再利用可能なウィジェットとして扱ってください。
- Lip Gloss をレイアウトとスタイリングとして扱ってください。
- Huh をフォームとウィザードを構築する最も速い方法として扱ってください。
- Glamour を markdown から ANSI へのレンダリングとして扱ってください。
- Log を TUI サーフェスではなく、
stderrまたはファイルへの診断として扱ってください。 - Wish をリモートターミナルアプリ用の SSH トランスポート層として扱ってください。
どのライブラリをいつ使用するか
| 必要 | 使用 |
|---|---|
| フル TUI、アプリの状態、キー処理、メッセージループ | references/bubbletea-core.md |
| 実際のアプリのアーキテクチャ、コマンド、子モデル、非同期パターン | references/bubbletea-patterns.md |
list、table、textinput、viewport、help などの再利用可能なウィジェット |
references/bubbles.md |
| フォーム、プロンプト、ウィザード、埋め込みフォーム画面 | references/huh.md |
| スタイリング、スペーシング、ボーダー、色、レイアウト構成 | references/lipgloss.md |
| SSH ネイティブ TUI またはリモート CLI アプリ | references/wish.md |
| Markdown ヘルプペイン、ドキュメント、リリースノート、プレビュー | references/glamour.md |
| 構造化された CLI ロギングと診断 | references/log.md |
| 高レベルのライブラリ選択と API マップ | references/api-surface.md |
| 具体的な実装レシピ | references/common-use-cases.md |
| 移行の問題と落とし穴 | references/troubleshooting-workarounds.md |
| アップストリームの例のショートリスト | references/examples.md |
デフォルトのビルド戦略
- ユーザーが TUI、ターミナル UI、ダッシュボード、ピッカー、ウィザード、またはインタラクティブな CLI を要求した場合は、Bubble Tea から開始します。
- 一般的なウィジェットを手動で再構築する代わりに、Bubbles を追加します。
- レイアウトまたは視覚的な階層が重要な場合は、Lip Gloss を追加します。
- インタラクションがフォーム中心の場合は、Huh を追加します。
- アプリが markdown コンテンツをレンダリングする場合は、Glamour を追加します。
- 診断、バックグラウンドジョブ、またはサーバーログには、Log を追加します。
- アプリを SSH 経由で実行する必要がある場合にのみ、Wish を追加します。
コアルール
- ビジネスロジックを Bubble Tea モデルから分離してください。
UpdateまたはViewで直接 I/O を行わず、tea.Cmdで I/O を行ってください。tea.WindowSizeMsgでサイズ変更を処理し、レイアウトをレスポンシブに保ってください。- スタイルがライト/ダークモードに依存する場合は、
tea.RequestBackgroundColorで背景色をリクエストしてください。 - Bubble Tea v2 では、
AltScreenやMouseModeなどのtea.Viewフィールドでターミナルの動作を宣言してください。 - スタンドアロンの Lip Gloss または Glamour 出力では、色のダウンサンプリングが機能するように、Lip Gloss ライターで出力してください。
- Wish アプリでは、ミドルウェアが宣言された順序と逆の順序で実行されることを覚えておいてください。
- Bubble Tea アプリでは、stdout ではなく、
stderrまたはファイルにログを書き込んでください。
Bubble Tea ファーストスケルトン
package main
import tea "charm.land/bubbletea/v2"
type model struct{}
func (m model) Init() tea.Cmd {
return nil
}
func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
switch msg := msg.(type) {
case tea.KeyPressMsg:
switch msg.String() {
case "q", "ctrl+c":
return m, tea.Quit
}
}
return m, nil
}
func (m model) View() tea.View {
v := tea.NewView("Hello from Bubble Tea")
return v
}
次に読むべきもの
- Bubble Tea のモデル、コマンド、メッセージ、およびプログラムのライフサイクルについては、
references/bubbletea-core.mdを読んでください。 - アプリの構造、非同期処理、Cobra 統合、およびマルチモデル構成については、
references/bubbletea-patterns.mdを読んでください。 - 古い Charmbracelet コードを移行したり、古い例を v2 コードと混在させたりする前に、
references/troubleshooting-workarounds.mdを読んでください。
📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開
Use this skill to build modern Go CLIs with the Charmbracelet stack. Default to Bubble Tea for any stateful TUI or interactive terminal flow, then layer in Bubbles, Huh, Lip Gloss, Wish, Glamour, and Log as needed.
Start Here
- Use
charm.land/.../v2imports for the current v2 ecosystem. - Treat Bubble Tea as the app runtime and state machine.
- Treat Bubbles as reusable widgets, not the app shell.
- Treat Lip Gloss as layout and styling.
- Treat Huh as the fastest way to build forms and wizards.
- Treat Glamour as markdown-to-ANSI rendering.
- Treat Log as diagnostics to
stderror files, not to the TUI surface. - Treat Wish as the SSH transport layer for remote terminal apps.
When To Reach For Which Library
| Need | Use |
|---|---|
| Full TUI, app state, key handling, message loop | references/bubbletea-core.md |
| Real app architecture, commands, child models, async patterns | references/bubbletea-patterns.md |
Reusable widgets like list, table, textinput, viewport, help |
references/bubbles.md |
| Forms, prompts, wizards, embedded form screens | references/huh.md |
| Styling, spacing, borders, color, layout composition | references/lipgloss.md |
| SSH-native TUI or remote CLI app | references/wish.md |
| Markdown help panes, docs, release notes, previews | references/glamour.md |
| Structured CLI logging and diagnostics | references/log.md |
| High-level library chooser and API map | references/api-surface.md |
| Concrete implementation recipes | references/common-use-cases.md |
| Migration issues and footguns | references/troubleshooting-workarounds.md |
| Upstream example shortlist | references/examples.md |
Default Build Strategy
- Start with Bubble Tea when the user asks for a TUI, terminal UI, dashboard, picker, wizard, or interactive CLI.
- Add Bubbles instead of rebuilding common widgets by hand.
- Add Lip Gloss once layout or visual hierarchy matters.
- Add Huh when the interaction is form-heavy.
- Add Glamour when the app renders markdown content.
- Add Log for diagnostics, background jobs, or server logs.
- Add Wish only when the app should run over SSH.
Core Rules
- Keep business logic separate from the Bubble Tea model.
- Do I/O in
tea.Cmd, not directly inUpdateorView. - Handle resize with
tea.WindowSizeMsgand keep layouts responsive. - Request background color with
tea.RequestBackgroundColorwhen styles depend on light/dark mode. - In Bubble Tea v2, declare terminal behavior in
tea.Viewfields likeAltScreenandMouseMode. - In standalone Lip Gloss or Glamour output, print with Lip Gloss writers so color downsampling works.
- In Wish apps, remember middleware runs in reverse declaration order.
- In Bubble Tea apps, write logs to
stderror a file, not to stdout.
Bubble Tea First Skeleton
package main
import tea "charm.land/bubbletea/v2"
type model struct{}
func (m model) Init() tea.Cmd {
return nil
}
func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
switch msg := msg.(type) {
case tea.KeyPressMsg:
switch msg.String() {
case "q", "ctrl+c":
return m, tea.Quit
}
}
return m, nil
}
func (m model) View() tea.View {
v := tea.NewView("Hello from Bubble Tea")
return v
}
Read These Next
- Read
references/bubbletea-core.mdfor Bubble Tea's model, commands, messages, and program lifecycle. - Read
references/bubbletea-patterns.mdfor app structure, async work, Cobra integration, and multi-model composition. - Read
references/troubleshooting-workarounds.mdbefore migrating old Charmbracelet code or mixing stale examples with v2 code.