mcp-onedev
TOD - TheOneDev CLIツール
TOD (TheOneDev) は、OneDev 13以降向けの強力なコマンドラインツールです。 ローカルの変更に対してCI/CDジョブを実行したり、プルリクエストをローカルの作業ディレクトリにチェックアウトしたり、イシュー/PR/ビルドのクエリや編集を行ったり、提供されているスキルファイルを通じてAIエージェントからこれらすべてを操作したりすることで、開発ワークフローを効率化します。
機能
OneDevエンティティのクエリと編集 — イシュー、プルリクエスト、ビルドをシェルから直接操作できます。
ローカルの変更、ブランチ、タグに対するCI/CDジョブの実行 — リアルタイムのログストリーミングに対応しています (
tod build run --local,--branch, または--tag)。プルリクエストのローカルチェックアウト (
tod pr checkout)。.onedev-buildspec.ymlのチェックと移行 — 最新バージョンへの更新をサポートします (tod build check-spec)。エージェントスキル —
skills/配下のスキルファイルにより、Claude Code、Cursor、その他SKILL.md対応エージェントがtodを介してOneDevワークフローを操作できるようになります。クロスプラットフォーム対応 (Windows, macOS, Linux)。
Related MCP server: AlibabaCloud DevOps MCP Server
インストール
tod をインストールするには、バイナリを PATH に配置してください。
ビルド済みバイナリのダウンロード
https://code.onedev.io/onedev/tod/~builds?query=%22Job%22+is+%22Release%22
ソースからのビルド
要件: Go 1.22.1 以上。
git clone https://code.onedev.io/onedev/tod.git
cd tod
go build設定
tod config set を実行して、対話形式で設定ファイルを作成または更新します:
tod config set
# OneDev server URL (e.g. https://onedev.example.com): ...
# OneDev personal access token (input is visible): ...または、非対話型セットアップのためにすべてをフラグとして渡します:
tod config set \
--server-url https://onedev.example.com \
--access-token your-personal-access-token \
--non-interactivetod config get はアクティブな設定(トークンは非表示)を表示し、tod config get <プロパティ名> は単一のプロパティを表示し、tod config set <プロパティ名> <プロパティ値> はプロパティを更新します。プロパティ名は server-url と access-token です。tod config path は使用されているパスを表示します。
設定ファイルは以下の場所で検索されます(最初に見つかったものが優先されます):
$XDG_CONFIG_HOME/tod/config~/.config/tod/config~/.todconfig(レガシーフォールバック)
INI形式を使用し、モード 0600 で書き込まれます:
server-url=https://onedev.example.com
access-token=your-personal-access-tokenクイックスタート
# Run CI against your uncommitted changes
cd /path/to/onedev-git-repository
tod build run --local ci
# Run ci job against the main branch
tod build run --branch main ci
# Check out pull request PROJ-123 into the current working directory
tod pr checkout PROJ-123
# Query open issues assigned to you
tod issue list --query 'assignee is me and state is "Open"'
# Inspect the most recent failing build for a project
tod build list --query 'successful is false' --count 1
tod build get <ref>
tod build get-log <ref>コマンドの詳細は cli.md を参照してください。
エージェントスキル
TODには、skills/ 配下に4つのツール非依存な SKILL.md ファイルが含まれており、AIエージェントがCLIを通じて一般的なOneDevワークフローを操作する方法を学習させることができます:
using-tod—todを介したOneDev操作全般のガイドedit-build-spec—.onedev-buildspec.ymlの作成または編集investigate-build-problems— 失敗したビルドのデバッグreview-pull-request— 構造化されたプルリクエストレビューの実行
これらをClaude Code、Cursor、または SKILL.md ファイルを読み取るその他のエージェントにインストールする方法については skills.md を参照してください。
ローカルCI実行時の注意点
Nginxの設定
OneDevがNginxの背後で動作している場合、ログストリーミングのためにHTTPバッファリングを無効にしてください:
location /~api/streaming {
proxy_pass http://localhost:6610/~api/streaming;
proxy_buffering off;
}詳細は OneDev Nginxセットアップドキュメント を参照してください。
セキュリティに関する考慮事項
ジョブがジョブシークレットにアクセスする場合、すべてのジョブを許可するために認証フィールドがクリアされていることを確認してください。認証をすべてのブランチに対して許可する設定だけでは不十分です。ローカルの変更は、どのブランチにも属さない一時的な参照にプッシュされるためです。
パフォーマンスのヒント
大規模リポジトリ — 完全な履歴ではなく、チェックアウトステップで適切なクローン深度を使用してください。
外部依存関係 — ダウンロードや中間ファイルには キャッシュ を使用してください。
ビルドの最適化 — 生成に時間がかかる中間ファイルをキャッシュしてください。
コントリビューション
TODはOneDevエコシステムの一部です。コントリビューション、イシュー、機能リクエストについては、OneDevプロジェクト を参照してください。
ライセンス
license.txt を参照してください。
This server cannot be deployed
Maintenance
Related MCP Connectors
AI-native git hosting — repos, PRs, issues, CI gates, and AI code review over MCP (60 tools).
Agentic CI operations for build inspection, failure diagnosis, and runner troubleshooting.
Manage repositories, users, releases, and automate GitHub workflows
Connect AI agents to CloudBees Unify: feature flags, CI/CD, release orchestration, and security
Related MCP Servers
- -licenseBqualityNot gradedmaintenanceEnables comprehensive Git and GitHub operations through 30 DevOps tools including repository management, file operations, workflows, and advanced Git features. Provides complete Git functionality without external dependencies for seamless integration with Gitea and GitHub platforms.18819 npm-
- AlicenseCqualityAmaintenanceEnables AI assistants to interact with Alibaba Cloud Yunxiao DevOps platform for managing projects, code repositories, work items, pipelines, deployments, and testing workflows through comprehensive organization, development, and delivery tools.81965 npm169Apache 2.0
- AlicenseNot gradedqualityDmaintenanceAutomates iteration management and code review submission workflows with DingTalk authentication. Supports interactive 5-step iteration creation, Git integration, smart time estimation, and automatic submission to company CodeReview systems.5 npm1ISC
- AlicenseNot gradedqualityDmaintenanceAutomates routine DevOps tasks like Jenkins builds and GitLab merge requests through the MCP protocol, simplifying daily operations.4 npm1MIT