원클릭으로
setup
Interactive setup wizard for new miniclaw users who just forked the repo
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Interactive setup wizard for new miniclaw users who just forked the repo
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Register bot commands with Telegram so they appear in the command menu
Rebuild miniclaw and restart the background service
Summarise recent conversations across all threads into auto memory (MEMORY.md + topic files)
Analyse chat history to update voice and typing style guide (voice.md in auto memory)
Create a semver release with changelog, git tag, and GitHub release
Review git diff and suggest how to group and commit changes
| name | setup |
| description | Interactive setup wizard for new miniclaw users who just forked the repo |
| disable-model-invocation | true |
| allowed-tools | Read, Edit, Bash(go *), Bash(which *), Bash(claude *), Bash(mkdir *), Bash(ls *), Bash(cat *), Bash(chmod *), Bash(systemctl *), Bash(loginctl *), Bash(curl *), Bash(uname *), Bash(launchctl *) |
You are helping a new user set up miniclaw after forking the repo. Walk through each step below in order. Check prerequisites first, then guide the user through configuration.
agent/CLAUDE.md. Only create/update ~/.miniclaw/.env and the agent configRun these checks silently and report the results as a checklist:
which go and go version. If which go fails, check ~/go/bin/go and /usr/local/go/bin/go. Require Go 1.23+.which claude. If that fails, check these common paths: ~/.claude/local/claude, /usr/local/bin/claude, ~/.npm-global/bin/claude. Once found, report the path and run <path> --version. This is required for the agent runtime. Assume the user is authenticated since they are already using Claude to set it up. Do not run any Claude commands yourself as it will fail.If any prerequisite is missing, tell the user what to fix and stop. Do not continue until all checks pass.
Important: Remember the directories where go and claude were found. These will be needed for the PATH in the launchd plist (macOS) in Step 12.
Run go mod tidy from the repo root to fetch all dependencies. Report success or failure.
Run go install ./cmd/miniclaw/ to compile and install the miniclaw binary to the user's $GOPATH/bin. Report success or failure.
Run mkdir -p ~/.miniclaw/{data/tasks,workspace}. This is already idempotent. Report that the runtime directory structure is ready.
Read agent/CLAUDE.md and show the user the current bot name (on line 3, e.g. "You are Enki"). Ask if they want to change it. Only edit the file if they request a change.
Before asking for configuration values, check if ~/.miniclaw/.env already exists by reading it with cat ~/.miniclaw/.env 2>/dev/null. Parse out the current values of:
TELEGRAM_BOT_TOKENALLOWED_CHAT_IDSMINICLAW_AGENT_DIRMINICLAW_TIMEZONEAlso check for GROQ_API_KEY.
Hold onto these values. Steps 7-11 will only prompt for values that are missing or empty.
If MINICLAW_TIMEZONE already has a non-empty value in the existing .env, report the current value and ask if they want to change it. If they don't, skip.
Otherwise, detect the server's timezone:
timedatectl show -p Timezone --valuereadlink /etc/localtime | sed 's|.*/zoneinfo/||'Show the detected timezone and ask the user if it matches their local timezone. If it does, skip MINICLAW_TIMEZONE entirely (the system fallback handles it). If it doesn't, ask for their IANA timezone (e.g. Asia/Singapore, Europe/London, America/New_York) and hold onto the value for the .env write step.
If TELEGRAM_BOT_TOKEN already has a non-empty value in the existing .env, report that a token is already configured (show a masked version, e.g. 714...XYz) and skip this step.
Otherwise, ask the user for their Telegram bot token. Tell them:
/newbot command and follow the promptsThe user may also choose to skip and add it later. Hold onto the value for Step 11.
Determine the absolute path to the agent/ directory in the current repo by running ls on it. This is the MINICLAW_AGENT_DIR value.
If the existing .env already has a correct MINICLAW_AGENT_DIR that matches this path, skip silently. Otherwise, hold onto the new value for Step 12.
If ALLOWED_CHAT_IDS already has a non-empty value in the existing .env, report the current value and ask if they want to change it. If they don't, skip.
Otherwise, ask the user for their allowed Telegram chat IDs (comma-separated). Tell them:
/chatid to the bot from any chat to get the ID-1001234567890)Hold onto the value for Step 12.
If GROQ_API_KEY already has a non-empty value in the existing .env, report that a key is already configured (show a masked version) and skip.
Otherwise, tell the user:
The user may skip this and add it later. Hold onto the value for Step 12.
If ~/.miniclaw/.env already exists and all values (TELEGRAM_BOT_TOKEN, ALLOWED_CHAT_IDS, MINICLAW_AGENT_DIR, MINICLAW_TIMEZONE, and optionally GROQ_API_KEY) are correct, report that the .env file is already up to date and skip writing.
Otherwise, write ~/.miniclaw/.env with the merged values (existing values for fields that didn't change, new values for fields that did):
TELEGRAM_BOT_TOKEN=<token>
ALLOWED_CHAT_IDS=<chat IDs>
MINICLAW_AGENT_DIR=<absolute path to agent/>
MINICLAW_TIMEZONE=<IANA timezone, if provided>
GROQ_API_KEY=<key, if provided>
Use the Bash tool to write this file with 0600 permissions. Do NOT use the Write tool (the path is outside the project).
First, detect the platform by running uname -s. If the result is Darwin, follow the macOS (launchd) path. Otherwise, follow the Linux (systemd) path.
Check if ~/.config/systemd/user/miniclaw.service already exists. If it does, read its contents and verify the ExecStart path is correct (matches which miniclaw).
systemctl --user is-enabled miniclaw) and skip to asking if they want to start/restart it.ExecStart is wrong, tell the user and offer to update it.If they decline, skip to Step 14.
To set up or update the service:
miniclaw binary by running which miniclaw or falling back to ls ~/go/bin/miniclaw.claude was found (from Step 1). This is the only extra PATH entry needed since miniclaw is referenced by absolute path in ExecStart and Claude's Bash tool reads the user's shell profile for its own PATH.mkdir -p ~/.config/systemd/user (idempotent).~/.config/systemd/user/miniclaw.service via the Bash tool with the following content:[Unit]
Description=miniclaw Telegram Bot
After=network-online.target
Wants=network-online.target
[Service]
Type=simple
EnvironmentFile=%h/.miniclaw/.env
Environment=PATH=<directory containing claude>:/usr/local/bin:/usr/bin:/bin
ExecStart=<absolute path to miniclaw binary>
Restart=on-failure
RestartSec=5
[Install]
WantedBy=default.target
systemctl --user daemon-reloadsystemctl --user enable miniclawloginctl enable-lingersystemctl --user start miniclaw and confirm it's running with systemctl --user status miniclaw.Check if ~/Library/LaunchAgents/com.miniclaw.agent.plist already exists. If it does, read its contents and verify the ProgramArguments path is correct (matches which miniclaw).
launchctl list | grep com.miniclaw.agent) and skip to asking if they want to start/restart it.If they decline, skip to Step 14.
To set up or update the service:
miniclaw binary by running which miniclaw or falling back to ls ~/go/bin/miniclaw.~/.miniclaw/.env and parse all key-value pairs. These will become EnvironmentVariables in the plist.PATH value that includes the directories where go, claude, and miniclaw were found (from Step 1 and above), plus standard paths: /usr/local/bin, /usr/bin, /bin, /usr/sbin, /sbin. Deduplicate entries.mkdir -p ~/Library/LaunchAgents (idempotent).~/Library/LaunchAgents/com.miniclaw.agent.plist via the Bash tool with the following content:<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.miniclaw.agent</string>
<key>ProgramArguments</key>
<array>
<string><absolute path to miniclaw binary></string>
</array>
<key>EnvironmentVariables</key>
<dict>
<key>PATH</key>
<string><constructed PATH from step 3></string>
<key>TELEGRAM_BOT_TOKEN</key>
<string><value></string>
<key>ALLOWED_CHAT_IDS</key>
<string><value></string>
<key>MINICLAW_AGENT_DIR</key>
<string><value></string>
<!-- include GROQ_API_KEY if set -->
</dict>
<key>RunAtLoad</key>
<true/>
<key>KeepAlive</key>
<true/>
<key>StandardOutPath</key>
<string>/tmp/miniclaw.log</string>
<key>StandardErrorPath</key>
<string>/tmp/miniclaw.log</string>
</dict>
</plist>
launchctl unload ~/Library/LaunchAgents/com.miniclaw.agent.plist 2>/dev/nulllaunchctl load ~/Library/LaunchAgents/com.miniclaw.agent.plistlaunchctl list | grep com.miniclaw.agentIf TELEGRAM_BOT_TOKEN is configured, ask the user if they want to register bot commands with Telegram so they appear in the command menu when typing /.
If they agree, invoke the /commands skill (read .claude/skills/commands/SKILL.md and follow its instructions).
If they decline, tell them they can run /commands later.
Print a summary:
Setup complete!
If they set up systemd (Linux), add:
miniclaw is running as a systemd user service.
systemctl --user status miniclaw # check status
systemctl --user restart miniclaw # restart after config changes
journalctl --user -u miniclaw -f # follow logs
If they set up launchd (macOS), add:
miniclaw is running as a launchd agent.
launchctl list | grep com.miniclaw.agent # check status
launchctl kickstart -k gui/$(id -u)/com.miniclaw.agent # restart
tail -f /tmp/miniclaw.log # follow logs
If they skipped the background service, add:
To run miniclaw:
miniclaw
In both cases, add:
To find your chat ID, send /chatid to your bot on Telegram,
then add it to ~/.miniclaw/.env as ALLOWED_CHAT_IDS.
If they left ALLOWED_CHAT_IDS empty, remind them to:
/chatid to the bot~/.miniclaw/.env