oil-oil

Computer Use Skill — Development skill for Claude Code

Development community

通过截图、鼠标和键盘操作 macOS 原生应用,处理没有可用 API 或专用工具的桌面任务.

How to install Computer Use Skill

This entry records only its repository, not the path inside it, so there is no exact command to give. Open oil-oil/computer-use-skill and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Computer Use Skill does

通过截图、鼠标和键盘操作 macOS 原生应用,处理没有可用 API 或专用工具的桌面任务。

Alternatives in Development

  • Codenotch — A macOS app that pins usage limits from Claude Code, Cursor, Codex, and Antigravity to a screen edge 1.3k ★
  • Lumenx Build — LumenX Studio 桌面应用构建流程 - macOS DMG 和 Windows EXE 打包 1.2k ★
  • Chops — 1,000+ macOS app to browse, edit, and manage skills across Claude Code, Cursor, Codex, Windsurf, and Amp 1.1k ★

README

computer-use — macOS 桌面操作 Skill

通过截图、鼠标和键盘操作 macOS 原生应用,处理没有可用 API 或专用工具的桌面任务。

[中文说明](#中文说明) · [Install](#install) · [Usage](#usage) · [How it works](#how-it-works)


Install

npx skills add oil-oil/computer-use-skill

手动安装时复制整个 Skill 目录,包括 `scripts/`;只复制 SKILL.md 无法运行初始化。

Prerequisites

**1. Install cliclick**

brew install cliclick

**2. Grant permissions** (System Settings → Privacy & Security)

Permission Required for Grant to
Screen Recording Taking screenshots Terminal / iTerm2
Accessibility Mouse clicks, keyboard input Terminal / iTerm2

Usage

Once installed, 直接向 Agent 描述任务:

  • "帮我打开 Safari 搜索 wolfcha"
  • "截个屏看看现在屏幕上是什么"
  • "帮我点击屏幕上的确认按钮"
  • "Open Safari and search for wolfcha"
  • "Take a screenshot and tell me what's on screen"
  • "Click the confirm button on screen"

How it works

No MCP server needed. This skill uses three native macOS tools:

Tool Purpose
screencapture Screenshot (built-in)
cliclick Mouse move / click (via Homebrew)
osascript Keyboard input, app activation (built-in)

The core loop is: **screenshot → analyze → act → screenshot to confirm**.

Key insight: always use `tell process "AppName"` inside `System Events` when sending keystrokes — not bare `keystroke` — otherwise input goes to the wrong focused app.

tell application "System Events"
    tell process "Safari"   -- ← specify the process, not just System Events
        keystroke "hello"
    end tell
end tell

中文说明

这是一个 [Claude Code](https://claude.ai/code) skill,让 Claude 可以直接操控你的 Mac:截图、移动鼠标、点击、输入文字、打开应用。

**不需要 Docker,不需要虚拟机**,只用 macOS 内置工具 + `cliclick`。

为什么不用 computer-use MCP?

是否有可用 MCP 或原生桌面工具,以当前宿主实际能力为准;优先使用专用工具。本 Skill 通过用户已授予的 macOS 权限工作,不用于绕过宿主的安全限制。

安装

brew install cliclick

使用上面的 Skill 安装命令,或把完整仓库复制到宿主扫描的 Skill 目录并重新加载。

使用

直接用自然语言告诉 Claude:

  • "帮我打开 Safari 搜索 wolfcha"