โ† All skills
Tencent SkillHub ยท Developer Tools

agentcli-go

agentcli-go framework reference for building Go CLI tools. Use when working on agentcli-go itself, scaffolding new CLI projects, adding commands, integrating...

skill openclawclawhub Free
0 Downloads
0 Stars
0 Installs
0 Score
High Signal

agentcli-go framework reference for building Go CLI tools. Use when working on agentcli-go itself, scaffolding new CLI projects, adding commands, integrating...

โฌ‡ 0 downloads โ˜… 0 stars Unverified but indexed

Install for OpenClaw

Quick setup
  1. Download the package from Yavira.
  2. Extract the archive and review SKILL.md first.
  3. Import or place the package into your OpenClaw setup.

Requirements

Target platform
OpenClaw
Install method
Manual import
Extraction
Extract archive
Prerequisites
OpenClaw
Primary doc
SKILL.md

Package facts

Download mode
Yavira redirect
Package format
ZIP package
Source platform
Tencent SkillHub
What's included
SKILL.md

Validation

  • Use the Yavira download entry.
  • Review SKILL.md after the package is downloaded.
  • Confirm the extracted package contains the expected setup assets.

Install with your agent

Agent handoff

Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.

  1. Download the package from Yavira.
  2. Extract it into a folder your agent can access.
  3. Paste one of the prompts below and point your agent at the extracted folder.
New install

I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete.

Upgrade existing

I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run.

Trust & source

Release facts

Source
Tencent SkillHub
Verification
Indexed source record
Version
1.0.0

Documentation

ClawHub primary doc Primary doc: SKILL.md 11 sections Open source page

agentcli-go

Shared Go CLI helpers and framework modules. Module: github.com/gh-xj/agentcli-go Repo: github.com/gh-xj/agentcli-go | Versioning: v0.x.y (pre-1.0)

API Surface

FileExported Symbolslog.goInitLogger() โ€” zerolog setup, respects -v/--verboseargs.goParseArgs(args), RequireArg(args, name), GetArg(args, name), HasFlag(args, name)exec.goRunCommand(name, args...), RunOsascript(script), Which(bin), CheckDependency(bin)fs.goFileExists(path), EnsureDir(path), GetBaseName(path)core_context.goAppContext{Meta, Values}, NewAppContext(ctx)lifecycle.goHook interface (Preflight, Postflight), RunLifecycle(app, hook, run)errors.goCLIError, ResolveExitCode(err), ExitSuccess, ExitUsagescaffold.goScaffoldNew(baseDir, name, module), ScaffoldAddCommand(rootDir, name, desc, preset), Doctor(rootDir) DoctorReportcobrax/cobrax.goExecute(RootSpec, args) int, NewRoot(RootSpec) *cobra.Command, CommandSpec, RootSpecconfigx/configx.goLoad(Options) map[string]any, Decode[T](raw), NormalizeEnv(prefix, environ)

New project

agentcli new --name my-tool --module github.com/me/my-tool # or programmatically: agentcli.ScaffoldNew(".", "my-tool", "github.com/me/my-tool") Generates: main.go, cmd/root.go, internal/app/, internal/config/, internal/io/, internal/tools/smokecheck/, pkg/version/, test/, Taskfile.yml, README.md

Add command

agentcli add command --name sync --preset file-sync agentcli add command --name deploy --desc "run deploy checks" Presets: file-sync, http-client, deploy-helper

Doctor check

agentcli doctor [--dir ./my-tool] # returns DoctorReport JSON with findings

Golden Project Layout

my-tool/ โ”œโ”€โ”€ main.go # os.Exit(cmd.Execute(os.Args[1:])) โ”œโ”€โ”€ cmd/ โ”‚ โ”œโ”€โ”€ root.go # cobrax.Execute(RootSpec{...}) โ”‚ โ””โ”€โ”€ <command>.go # func <Name>Command() command โ”œโ”€โ”€ internal/ โ”‚ โ”œโ”€โ”€ app/{bootstrap,lifecycle,errors}.go โ”‚ โ”œโ”€โ”€ config/{schema,load}.go โ”‚ โ”œโ”€โ”€ io/output.go โ”‚ โ””โ”€โ”€ tools/smokecheck/main.go โ”œโ”€โ”€ pkg/version/version.go โ”œโ”€โ”€ test/ โ”‚ โ”œโ”€โ”€ e2e/cli_test.go โ”‚ โ””โ”€โ”€ smoke/version.schema.json โ””โ”€โ”€ Taskfile.yml

cobrax Pattern

// cmd/root.go return cobrax.Execute(cobrax.RootSpec{ Use: "my-tool", Short: "my-tool CLI", Meta: agentcli.AppMeta{Name: "my-tool", Version: version.Version}, Commands: []cobrax.CommandSpec{ {Use: "sync", Short: "sync files", Run: SyncCommand().Run}, }, }, args) Persistent flags auto-wired: --verbose/-v, --config, --json, --no-color Values accessible via app.Values["json"], app.Values["config"], etc.

configx Pattern

raw, err := configx.Load(configx.Options{ Defaults: map[string]any{"env": "default"}, FilePath: configPath, // optional JSON file Env: configx.NormalizeEnv("MYTOOL_", os.Environ()), Flags: map[string]string{"env": flagVal}, }) cfg, err := configx.Decode[config.Config](raw) // Precedence: Defaults < File < Env < Flags

Taskfile Tasks

TaskPurposetask ciCanonical CI: preflight + lint + test + build + smoke + schema checkstask verifyLocal aggregate (wraps ci)task lintgo vet + golangci-linttask smokeDeterministic smoke tests (subset of unit tests)task schema:checkValidate JSON contracts against schemastask docs:checkEnsure skill docs match CLI help signaturestask fmtFormat all Go files

Rules

Flat package โ€” everything in package agentcli, no sub-packages (except cobrax, configx) Exported only โ€” all functions PascalCase; this is a library No business logic โ€” generic utilities only; must be reused across 2+ projects to qualify log.Fatal allowed in RequireArg, CheckDependency (CLI-oriented helpers) Minimal deps โ€” zerolog, lo, cobra only; justify new additions

Out of Scope

Project-specific logic (put that in consuming projects) Adding functions used by only one project

Category context

Code helpers, APIs, CLIs, browser automation, testing, and developer operations.

Source: Tencent SkillHub

Largest current source with strong distribution and engagement signals.

Package contents

Included in package
1 Docs
  • SKILL.md Primary doc