← 返回
开发者工具 中文

OpenClaw Copilot CLI Wrapper

Run GitHub Copilot CLI via exec to generate code, edit files, or automate shell tasks using advanced AI models like Claude or GPT-5.
通过 exec 调用 GitHub Copilot CLI,利用 Claude 或 GPT-5 等先进 AI 模型生成代码、编辑文件或自动化 Shell 任务。
binotaliu
开发者工具 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 801
下载
💾 10
安装
1
版本
#latest

概述

copilot-cli

Description

Execute GitHub Copilot CLI via exec for code gen, file edits, shell tasks using advanced models (Claude/GPT-5). Use when needing Copilot-powered coding/automation.

Installation

npm install -g @github/copilot

or on macOS:

brew install copilot-cli

Verify:

copilot --help

Authentication

  1. Run copilot (interactive mode).
  2. Type /login and follow prompts (uses GitHub account, requires Copilot subscription).

For non-interactive use after auth.

Usage

Non-interactive (one-shot prompts)

copilot -p \"Your prompt here\" --allow-all --silent
  • --allow-all: Enables all tools/paths/URLs (use --yolo for short).
  • --silent: Outputs only agent response.
  • --model claude-sonnet-4.6 or gpt-5.2 etc. to choose model.

In OpenClaw exec:

exec:
  command: copilot -p 'Generate a Python script to...' --allow-all --silent

Interactive

exec:
  command: copilot
  pty: true

Then use process tool:

  • send-keys: Send input like ['prompt text', 'Enter']
  • log: View output

Examples

Shell task

copilot -p 'List all .js files and summarize' --allow-all

Code generation

copilot -p 'Create a simple Express server in Node.js' --allow-all --silent

File edits

copilot -p 'Add error handling to main.js' --allow-all

Advanced models

copilot -p '...' --model gpt-5.3-codex --allow-all

Test

Tested: Generated hello_world.sh:

#!/bin/bash
echo \"Hello, World!\"

Solana NFT mint test started successfully (complex task running).

Tips

  • Custom instructions from AGENTS.md auto-loaded.
  • Use --no-custom-instructions if needed.
  • For scripting: --share to output session.md
  • Logs: ~/.copilot/logs/

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-30 07:19 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

developer-tools

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 672 📥 324,520
developer-tools

Gog

steipete
Google Workspace 命令行工具,支持 Gmail、日历、云端硬盘、通讯录、表格和文档。
★ 921 📥 185,925
developer-tools

CodeConductor.ai

larsonreever
AI驱动平台,提供快速全栈开发、智能体、工作流自动化及低代码AI集成的可扩展产品创建。
★ 68 📥 180,469