Skip to content

meloalright/shell-acp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

shell-acp

CI License: MIT Homebrew npm

A shell exposed as an ACP agent.

It speaks ACP (JSON-RPC 2.0 over stdio), so an ACP client such as cc-connect spawns it as a backend and bridges it to Telegram, Lark, Slack, Discord, and more — every message becomes a command, and the output streams back.

一款命令行的 ACP 实现。可用 ACP 客户端如 cc-connect 把它连接至飞书、微信、QQ、电报等 —— 以实现在聊天中运行命令行。

Telegram 飞书

Left: Telegram  |  Right: Lark

Installation

⚡️ install via homebrew
brew install meloalright/tap/shell-acp
⚡️ install via npm
npm install -g shell-acp

Usage

Add it to your cc-connect config.toml as an acp agent:

[projects.agent]
type = "acp"

[projects.agent.options]
work_dir = "/root"
command = "/usr/local/bin/shell-acp"
display_name = "shell-acp terminal"

Restart cc-connect, then talk to the bot. Send any shell command as a message; control the session in-band:

Message Effect
<any command> run it; output streams back as one code block
@shell ctrl-c interrupt the foreground job (Ctrl-C)
@shell ctrl-d send EOF (exit a REPL/shell)
@shell stop kill the shell session