360 Secure SkillHub
360 安全技能中心

Weclaw Installer

在 macOS 上自动化安装并配置 WeClaw 微信机器人:检查 git、uv、python3 前置条件,克隆项目仓库,用 uv 配置 Python 依赖,写入 API key 与 .env,并引导处理辅助功能权限阻塞;另含发布到 ClawHub 的路径与 workdir 说明。

popilopi168
popilopi168
热度 33.55
最近更新 2026-05-11 17:38:25
分类:自动化依赖:代码执行 / 读写文件 / 第三方 API应用场景:自动化脚本 / 工作流 / DevOps / API 集成

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add weclaw-installer
Metadata
name
weclaw-installer
description
Automate installing and configuring the WeClaw WeChat bot environment on macOS. Use when the user asks to download/install WeClaw, set up a local Python environment with uv, or gets blocked on macOS Accessibility permissions / API key setup.
metadata
{"openclaw":{"os":["darwin"],"requires":{"bins":["git","uv","python3"]}}}

Source repository

The installer clones this repo into a local folder named weclaw-package-upload-test:

ClawHub

  • Slug: weclaw-installer

Why Path must be a folder: The ClawHub CLI resolves paths as resolve(workdir, <path>). If your current directory has no .clawhub marker, workdir defaults to your OpenClaw workspace (not this repo), so skills/weclaw-installer points nowhere.

This repo includes a .clawhub/ folder so that when your shell cd is the repo root, workdir stays the repo.

Publish (from repo root, recommended):

clawhub publish skills/weclaw-installer --version 1.0.0 --slug weclaw-installer

If you still see the error (e.g. CLAWHUB_WORKDIR overrides), use an explicit workdir or an absolute path:

clawhub --workdir "$(pwd)" publish skills/weclaw-installer --version 1.0.0 --slug weclaw-installer
# or
clawhub publish /absolute/path/to/weclaw-installer-plugin/skills/weclaw-installer --version 1.0.0 --slug weclaw-installer

When to use

Use this skill when the user wants to:

  • Install / download / bootstrap the WeClaw project locally
  • Set up Python dependencies with uv
  • Configure an API key / .env
  • Fix common macOS setup blockers (especially Accessibility permission)

Workflow

  1. Ensure prerequisites are available: git, uv, python3.
  2. If macOS Accessibility permission is not enabled, open the System Settings page and instruct the user to enable it for the terminal/app running the automation.
  3. Ask the user for the required API key if it is not already provided.
  4. Run the setup entrypoint to perform the automated steps.

Entrypoint (wrapper script)

Run:

  • python3 scripts/run_setup.py

To pass the API key non-interactively:

  • python3 scripts/run_setup.py --api-key "<KEY>"

After the user has enabled macOS Accessibility permission:

  • python3 scripts/run_setup.py --api-key "<KEY>" --mac-permission-confirmed

Safety / guardrails

  • Do not request or store unrelated secrets.
  • Only write .env / config values that are explicitly required for WeClaw setup.
  • If a step fails, surface the exact error output and suggest the smallest next fix.