desktop-bridge
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinesedesktop-bridge
Desktop-Bridge 文件桥接工具
File bridge: user's devices ↔ agent workspace via WebDAV + Cloudflare Tunnel.
Start
- Before starting, ask the user: read-only or full read-write access?
bash {baseDir}/scripts/start.sh --path "$HOME/workspace"- Add if user chose read-only
--read-only - Prints tunnel URL + credentials. Give all three to the user.
- custom port (default 8080)
--port 9090 - custom credentials (default: bridge / auto-generated)
--user alice --pass secret - First positional arg = for convenience
--path
Stop
bash {baseDir}/scripts/stop.sh
Status
bash {baseDir}/scripts/status.sh- Shows connection info if running, suggests start if not
How the user connects (tell them)
- macOS Finder: Cmd+K → paste URL
- Windows Explorer: Map Network Drive → paste URL
- Linux GNOME: Files → Other Locations → + hostname
davs:// - Linux KDE: Dolphin → + hostname
webdavs:// - iOS Files: Connect to Server → paste URL
- Android: CX File Explorer → Remote → WebDAV (host, port 443, HTTPS)
- Obsidian: Remotely Save plugin → WebDAV → paste URL
- Enter username and password when prompted
Manual install (if brew is unavailable)
- rclone: or download from https://rclone.org/downloads/
curl -fsSL https://rclone.org/install.sh | bash - cloudflared: download from https://github.com/cloudflare/cloudflared/releases/latest
Notes
- Tunnel URL changes on every restart (free Cloudflare quick tunnel).
- 100 MB max file size (Cloudflare free tier limit).
- Bridge runs in background — no open terminal needed.
- Always stop when user is done.
- State files in (never in skill dir).
${DESKTOP_BRIDGE_DIR:-${TMPDIR:-/tmp}/desktop-bridge}
文件桥接工具:通过WebDAV + Cloudflare Tunnel实现用户设备与Agent工作区的文件互通。
—
启动
—
- 启动前,请询问用户: 需要只读权限还是完整的读写权限?
- 执行命令:
bash {baseDir}/scripts/start.sh --path "$HOME/workspace" - 如果用户选择只读权限,添加参数
--read-only - 输出隧道URL和凭据。请将这三项全部提供给用户。
- 自定义端口(默认8080)
--port 9090 - 自定义凭据(默认:用户名bridge,密码自动生成)
--user alice --pass secret - 为方便使用,第一个位置参数等同于参数
--path
—
停止
—
- 执行命令:
bash {baseDir}/scripts/stop.sh
—
查看状态
—
- 执行命令:
bash {baseDir}/scripts/status.sh - 如果工具正在运行,显示连接信息;如果未运行,提示启动
—
用户连接方式(告知用户)
—
- macOS Finder:按下Cmd+K → 粘贴URL
- Windows 资源管理器:点击「映射网络驱动器」→ 粘贴URL
- Linux GNOME:打开「文件」→ 「其他位置」→ 输入+ 主机名
davs:// - Linux KDE:打开Dolphin → 输入+ 主机名
webdavs:// - iOS 文件应用:点击「连接到服务器」→ 粘贴URL
- Android:打开CX文件管理器 → 「远程」→ 选择WebDAV(填写主机名、端口443、HTTPS协议)
- Obsidian:使用Remotely Save插件 → 选择WebDAV → 粘贴URL
- 出现提示时输入用户名和密码
—
手动安装(当brew不可用时)
—
- 安装rclone:执行或从https://rclone.org/downloads/下载安装包
curl -fsSL https://rclone.org/install.sh | bash - 安装cloudflared:从https://github.com/cloudflare/cloudflared/releases/latest下载安装包
—
注意事项
—
- 每次重启后隧道URL会变化(这是Cloudflare免费快速隧道的特性)。
- 最大文件大小为100MB(Cloudflare免费版限制)。
- 桥接工具在后台运行,无需保持终端窗口打开。
- 用户使用完毕后请务必停止工具。
- 状态文件存储在目录下(切勿存放在skill目录中)。
${DESKTOP_BRIDGE_DIR:-${TMPDIR:-/tmp}/desktop-bridge}