One command setup flow
Bundle CLI configure + authenticate + daemon start into one `cli setup` command, with per-environment profiles (cloud vs self-host) and custom-port overrides.From its SKILL.md
npx -y skills add kjuhwa/skills-hub --skill one-command-setup-flowAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
3.2 KB, 717 tokens by cl100k_base, as published. Nobody here has run it
When to use
- A CLI where first-time setup has always required 3-5 manual steps (config set, login, start daemon).
- You want a single command to onboard users, with sensible defaults for cloud and self-host.
Steps
- Define a
setupcommand with two modes:
Defaultsetup := &cobra.Command{ Use: "setup", Short: "Configure, authenticate, and start the daemon", } setup.AddCommand(selfHostCmd()) // mycli setup self-host rootCmd.AddCommand(setup)setupuses cloud endpoints;setup self-hosttargets localhost with overridable flags. setup self-hostflags let users override defaults without editing config:cmd.Flags().StringVar(&serverURL, "server-url", "http://localhost:8080", "") cmd.Flags().StringVar(&appURL, "app-url", "http://localhost:3000", "") cmd.Flags().Int( "port", 8080, "backend port (sets server-url)") cmd.Flags().Int( "frontend-port", 3000, "frontend port (sets app-url)") cmd.Flags().String("profile", "", "profile name (default: derived from URL)")- Implementation is a sequence of small, idempotent steps, each recoverable:
1. Resolve server/app URL from flags or defaults 2. Write to profile config (~/.mycli/profiles/<name>/config.json) 3. Open browser to {appURL}/auth/cli-callback?port=<local listener> 4. Wait for callback with token on localhost 5. Save token to profile config 6. Fetch workspace list with the token 7. Start daemon in the background with this profile 8. Poll daemon health endpoint until ready 9. Print success banner + "what next" hints - Each step can be re-run independently:
mycli loginrepeats steps 3-5.mycli config set server_url ...repeats step 2.mycli daemon startrepeats steps 7-8.
- Prompt before overwriting an existing profile config (don't clobber silently).
Example
$ mycli setup self-host --port 9090 --frontend-port 4000
==> Writing config to ~/.mycli/profiles/localhost-9090/config.json
==> Opening browser for authentication...
(paste token if browser doesn't open: http://localhost:4000/auth/cli)
✓ Authenticated as [email protected]
==> Discovered 2 workspaces: "Engineering", "Marketing"
==> Starting daemon (profile: localhost-9090)...
✓ Daemon running (PID 12345)
Next: assign an issue to an agent from http://localhost:4000
Caveats
- Browser-less environments (CI, VM without X): flag
--tokenpath that reads a PAT from stdin or env; don't force browser auth. - Daemon start + healthcheck poll with a 60s timeout; if it fails, print the log path and exit non-zero.
- Profile name derivation must be deterministic (by URL or worktree), so re-running
setuptargets the same profile.
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.