Skip to content
cccskills
FreePublished on GitHub

shiiman-common:brew-upgrade-ai

AI 関連 CLI ツールを brew で一括アップグレードする。「AI ツール更新」「brew upgrade AI」「AI CLI 更新」「ツール一括更新」「claude/codex/cursor/gemini 更新」などで起動。

The English summary is being prepared. Showing the original description.

See how to install

Files included (1)

  • SKILL.md5.3 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

Brew Upgrade AI

AI 関連 CLI ツールを brew で一括アップグレードします。

Help

$ARGUMENTS に --help が含まれる場合、以下を表示して終了:

/shiiman-common:brew-upgrade-ai - AI ツール一括更新

概要:
  AI 関連 CLI ツール(claude-code@latest, codex, cursor-cli, gemini-cli)を
  brew で一括アップグレードします。

使用方法:
  /shiiman-common:brew-upgrade-ai [オプション]

オプション:
  --help    このヘルプを表示

例:
  /shiiman-common:brew-upgrade-ai     # AI ツールを一括更新

対象ツール

brew パッケージ名ツール名
claude-code@latest(fallback: claude-code)Claude Code
codexCodex
cursor-cliCursor CLI
gemini-cliGemini CLI

ワークフロー

1. 現在のバージョン確認

Bash ツールで以下を並列実行し、各ツールのインストール状態・パッケージ種別・現在のバージョンを取得:

  • brew list --cask --versions claude-code@latest 2>/dev/null || brew list --cask --versions claude-code 2>/dev/null || brew list --versions claude-code 2>/dev/null || echo "NOT_INSTALLED"
  • brew list --cask --versions codex 2>/dev/null || brew list --versions codex 2>/dev/null || echo "NOT_INSTALLED"
  • brew list --cask --versions cursor-cli 2>/dev/null || brew list --versions cursor-cli 2>/dev/null || echo "NOT_INSTALLED"
  • brew list --cask --versions gemini-cli 2>/dev/null || brew list --versions gemini-cli 2>/dev/null || echo "NOT_INSTALLED"

判定ルール:

  • brew list --cask --versions で取得できた場合: type=cask、出力先頭トークンを実際のパッケージ名として記録(例: claude-code@latest)
  • brew list --versions で取得できた場合: type=formula、コマンドに渡したパッケージ名をそのまま記録
  • どちらも取得できない場合: NOT_INSTALLED

未インストール(NOT_INSTALLED)のツールはスキップ対象として記録。手順 2・3 では記録したパッケージ名を使う。

2. アップグレード実行

インストール済みのツールのみ、判定された type に応じて Bash ツールで並列実行:

  • type=cask の場合: brew upgrade --cask <package> 2>&1
  • type=formula の場合: brew upgrade <package> 2>&1

各コマンドの出力から以下を判定:

  • 更新済み: バージョンが変わった場合
  • 最新: 以下のいずれかを含む場合
    • already installed
    • already up-to-date
    • Not upgrading
  • エラー: その他のエラー出力

3. 新バージョン確認

インストール済みツールについて、type に応じたコマンドを 並列実行 して新バージョンを取得:

  • type=cask の場合: brew list --cask --versions {パッケージ名}
  • type=formula の場合: brew list --versions {パッケージ名}

4. 結果表示

以下のフォーマットで結果を出力:

## AI ツール更新結果

| ツール             | 旧バージョン | 新バージョン | 状態           |
| ------------------ | ------------ | ------------ | -------------- |
| claude-code@latest | x.x.x        | y.y.y        | 更新済み       |
| codex              | x.x.x        | x.x.x        | 最新           |
| cursor-cli         | -            | -            | 未インストール |
| gemini-cli         | x.x.x        | y.y.y        | 更新済み       |

> 「ツール」列には手順 1 で記録した実際のパッケージ名(Claude Code なら `claude-code@latest` または `claude-code`)を表示する。

状態の表記:

状態条件
更新済みバージョンが変わった
最新既に最新バージョン
未インストールbrew にパッケージが存在しない
エラーupgrade コマンドが失敗(エラー詳細付記)

重要な注意事項

  • ✅ claude-code / codex / cursor-cli は環境によって cask 管理の場合があるため、必ず cask → formula の順で確認する
  • ✅ Claude Code は claude-code@latest(cask) → claude-code(cask) → claude-code(formula)の順で確認し、ヒットしたパッケージ名を upgrade・再確認でそのまま使う
  • ✅ 未インストールのツールはスキップ(エラーにしない)
  • ✅ 各 brew upgrade は並列実行して高速化
  • ✅ 旧バージョン・新バージョンを比較して状態を判定
  • ❌ 未インストールのツールを自動インストールしない
  • ❌ brew 以外のパッケージマネージャは使用しない

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

プラグインに新しいフックを作成する。「フック作成」「新しいフック」「フックを作って」「フック追加」「hook 作成」「フックを追加したい」「新規フック」などで起動。ツール実行前後やセッションイベントで実行されるフックを生成。

The English summary is being prepared. Showing the original description.

shiiman/claude-code-plugins6Updated Jun 17, 2026

マーケットプレイスのソースを dev(directory)/ prd(git)に切り替える。「マーケットプレイス切替」「marketplace toggle」「dev モード」「prd モード」「ローカル開発モード」「開発モード切替」「マーケットプレイス dev」などで起動。

The English summary is being prepared. Showing the original description.

shiiman/claude-code-plugins6Updated Jun 17, 2026

新しい Claude Code プラグインを作成する。「プラグイン作成」「新しいプラグイン」「プラグインを作って」「プラグイン追加」「plugin 作成」「プラグイン一括作成」「フル作成」などで起動。プラグインのみ作成と、スキル/サブエージェント/フックを含む一括作成の両方に対応。

The English summary is being prepared. Showing the original description.

shiiman/claude-code-plugins6Updated Jun 17, 2026

MCP サーバーの一覧表示・追加・削除を一つのスキルで管理する。「MCP 管理」「MCP 一覧」「MCP を追加」「MCP を削除」「MCP サーバー管理」「MCP 設定」「MCP 操作」などで起動。引数があれば優先し、なければ発話内容から list/install/remove を判定。

The English summary is being prepared. Showing the original description.

shiiman/claude-code-plugins6Updated Jun 17, 2026

プロジェクトの Claude Code リソース一覧を表示する。「Claude リソース一覧」「スキル一覧」「エージェント一覧」「フック一覧」「プロジェクトリソース確認」「何があるか確認」「リソースを見せて」などで起動。表示対象(スキル/エージェント/フック)は発話から判断する。

The English summary is being prepared. Showing the original description.

shiiman/claude-code-plugins6Updated Jun 17, 2026

Claude Code 設定の表示・更新・ローカル更新を統合管理する。「Claude 設定管理」「設定を表示」「settings を更新」「local settings を更新」「権限設定を変更」「設定ファイル管理」「claude settings」などで起動。引数があれば優先し、なければ発話内容から view/update/local-update を判定。

The English summary is being prepared. Showing the original description.

shiiman/claude-code-plugins6Updated Jun 17, 2026

See all skills by shiiman

Report a problem with this skill