Skill: popilopi168/weclaw-installer (version 1.0.0)

--- 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`: - https://github.com/Popilopi168/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):** ```bash 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: ```bash 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.

path: scripts/run_setup.py
content: import argparse
from pathlib import Path
import sys


def _repo_root() -> Path:
    return Path(__file__).resolve().parents[3]


def main() -> int:
    parser = argparse.ArgumentParser(
        description="Run WeClaw installer setup_package.py wrapper"
    )
    parser.add_argument("--api-key", default=None, help="API key for setup")
    parser.add_argument(
        "--mac-permission-confirmed",
        action="store_true",
        help="Set when macOS Accessibility permission is enabled",
    )
    args = parser.parse_args()

    repo_root = _repo_root()
    sys.path.insert(0, str(repo_root))

    try:
        from setup_package import setup_openclaw_package  # type: ignore
    except Exception as e:
        print(f"STATUS: FAILED. Could not import setup_package.py: {e}")
        return 1

    result = setup_openclaw_package(
        [REDACTED_SECRET],
        mac_permission_confirmed=bool(args.mac_permission_confirmed),
    )
    print(result)
    return 0 if isinstance(result, str) and result.startswith("STATUS: SUCCESS") else 2


if __name__ == "__main__":
    raise SystemExit(main())



Security scan verdicts — ClawScan: suspicious | static analysis: clean | VirusTotal: clean | SkillSpector: clean (LOW)