Golang Pkg Go Dev logo

Golang Pkg Go Dev

CommunityPopular
samber
golang-pkg-go-dev

Golang package and module lookup via `godig`, a pkg.go.dev API client (CLI + MCP server). Use for any Go/Golang library's documentation, API signatures, symbols, usage examples, which versions exist, licenses, whether a dependency has CVEs, or who imports a package — prefer this over Context7 for any Go package or module. Read-only, no auth. Not for upgrading dependencies (→ See `samber/cc-skills-golang@golang-dependency-management` skill), choosing a library (→ See `samber/cc-skills-golang@golang-popular-libraries` skill), or local symbols and an already-used dependency's resolved source, call sites, and generic instantiations (→ See `samber/cc-skills-golang@golang-gopls` skill).

Overview

Publishersamber
Repositorycc-skills-golang
Skill namegolang-pkg-go-dev
Stars
3.3K
Forks
213
Bundled files
1
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 1 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by samber on GitHub. Read the source before you install it.

Installation

Install the Golang Pkg Go Dev AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/samber/cc-skills-golang.git /tmp/cc-skills-golang
mkdir -p .claude/skills
cp -r /tmp/cc-skills-golang/skills/golang-pkg-go-dev .claude/skills/golang-pkg-go-dev
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Golang Pkg Go Dev in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Golang Pkg Go Dev on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Golang Pkg Go Dev is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

golang-pkg-go-dev

Dependencies: godiggo install github.com/samber/godig/cmd/godig@latest (or use a registered godig MCP server / the hosted instance instead).

godig queries the pkg.go.dev API. Use it to answer questions about Go packages and modules: docs, symbols, versions, importers and vulnerabilities. It works as a CLI and as an MCP server, and all operations are read-only and need no authentication.

When to use this skill

Trigger on questions like:

  • "What versions of github.com/samber/lo are available?"
  • "Does golang.org/x/text have known vulnerabilities?"
  • "Show me the docs / symbols for package X."
  • "Which packages import X?"
  • "Search Go packages for Y."

Choosing between godig, gopls, Context7, and govulncheck

In short: godig answers questions about the published ecosystem (works even for packages not yet in your go.mod); gopls reasons about your locally resolved build (go.sum, including replaced forks); Context7 is a fallback for non-Go or unindexed docs; govulncheck is the whole-tree vulnerability audit (→ samber/cc-skills-golang@golang-security). See the samber/cc-skills-golang@golang-gopls skill for wiring gopls (MCP server, native LSP tool, and CLI) with Claude Code, and the samber/cc-skills-golang@golang-how-to skill's "godig vs gopls vs Context7 vs govulncheck" section for the full task-to-tool matrix.

Setup

Install

bash
go install github.com/samber/godig/cmd/godig@latest

Register the MCP server (optional)

godig mcp runs over stdio by default, or streamable HTTP with --transport http. The command is harness-agnostic — any MCP-capable host can point at it. Claude Code registers it via its own CLI:

stdio (the client launches godig on demand):

bash
claude mcp add pkg-go-dev -- godig mcp

streamable HTTP (shared server at /mcp, default :8080):

bash
godig mcp --transport http --addr :8080
claude mcp add --transport http pkg-go-dev http://localhost:8080/mcp

Hosted instance (no install needed) — a public server runs at https://godig.samber.dev/mcp:

bash
claude mcp add --transport http pkg-go-dev https://godig.samber.dev/mcp

Other MCP-capable harnesses (Cursor, Windsurf, and others) each have their own MCP server registration — an entry in their respective settings file pointing at the same godig mcp command or hosted URL, not a shared config format.

The CLI and the MCP server expose the same operations under matching names. Prefer the CLI when godig is installed; the hosted instance is a fallback when it is not.

Commands

Global flags (all commands): -o/--output table|json|raw|md (default table — pass -o md for chat), --base-url (pkg.go.dev API), --vuln-base-url (Go vulnerability database, consulted by vulns and overview), --timeout, --log-level debug|info|warn|error|off. All are also settable via GODIG_* env vars.

CommandArgsSpecific flagsPurpose
overview<path>--versionCompact summary (metadata, versions, licenses, vulns) — start here
search<query>--symbol --limit --filterFind packages (optionally exporting a symbol)
package info<path>--module --versionPackage metadata
package imports<path>--module --versionPackages this package imports (plain list)
package doc<path>--module --version --goos --goarch --format md|text|html|markdownFull package doc (LARGE)
package examples<path>--module --version --goos --goarch --symbolRunnable examples (LARGE; scope with --symbol)
package licenses<path>--module --versionLicense files, full text (LARGE)
symbol doc<path> <symbol>--module --version --goos --goarchOne symbol's signature + doc (token-efficient)
symbol examples<path> <symbol>--module --version --goos --goarchOne symbol's runnable examples
symbols<path>--module --version --goos --goarch --limit --filterList exported symbols
module info<path>--versionModule metadata
module licenses<path>--versionModule license files (LARGE)
module readme<path>--versionModule README, full Markdown (LARGE)
dependencies<path>--versiongo.mod deps: requires / replaces / excludes / go directive
packages<path>--version --limit --filterPackages contained in a module
versions<path>--limit --filterAll versions, newest first
major-versions<path>--limit --filter --exclude-pseudoMajor versions (v1, v2 …) living as separate modules
imported-by<path>--module --version --limit --filterPackages that import this one
vulns<path>--version --limitKnown vulnerabilities (from the Go vuln DB)
mcp--transport stdio|http --addr --cache-ttl --cache-sizeRun as an MCP server
versionPrint godig version / commit / build date

When godig runs as an MCP server, each data command above is exposed as an operation of the same name.

Exit codes: 0 success, 1 runtime error (network, package not found), 2 usage error — a missing/invalid argument or flag (e.g. a non-positive --limit), or a command group invoked with no subcommand (godig package). Check for 2 to tell a malformed call apart from a failed lookup.

Full -o md output for every command: sample-output.md.

Tips

  • Start with overview — one call returns a compact summary (metadata, latest + recent versions, license types, vulnerabilities). Reach for doc/examples/module readme/licenses (LARGE) only when the full text is needed.
  • Always pass -o md so results render as Markdown (tables, or raw doc/README) in the chat. Other formats exist (table default, json, raw) but prefer md here.
  • <path> is a full import path, e.g. github.com/samber/lo — pass it as the positional argument.
  • --version pins a specific module version (v1.5.0, latest, master, main); --module disambiguates which module a package belongs to.
  • --filter narrows list results server-side with a Go boolean expression — see Filter syntax.
  • --goos/--goarch set the documentation/symbols build context (e.g. linux/amd64).
  • Prefer symbol doc/symbol examples over the package-wide package doc/package examples when you only need one symbol — far fewer tokens.
  • Parallelize independent lookups — every command is a self-contained, read-only HTTP query, so calls never depend on each other. When a task needs docs, examples, versions, or vulns for several symbols, packages, or modules, issue all the calls at once (multiple godig invocations in a single turn) rather than one after another — wall-clock drops from sum-of-latencies to slowest-single-call. For a large fan-out (documenting many symbols, comparing many candidate libraries, auditing CVEs across a dependency set), dispatch up to 5 parallel sub-agents, each running its own godig calls and returning a compact summary, so the raw LARGE output never lands in the main context.
  • Listing commands auto-paginate (return all results); use --limit to cap.

Filter syntax

--filter (on search, versions, major-versions, packages, imported-by, symbols) takes a Go boolean expression evaluated server-side, once per result item. It is not a regex — wrap the whole expression in single quotes for the shell.

  • Identifiers are the item's fields, which differ per command — a field valid for one list is rejected by another (e.g. search exposes packagePath, not path). An unknown field fails with undefined identifier: <name> (HTTP 400), which names the offending field. Fields use the item's lowercase JSON key; the exception is enum-like values such as kind, which are capitalized (Function, not func).
  • Operators: == != < <= > >=, boolean && || !, parentheses for grouping.
  • String functions: contains(s, sub), hasPrefix(s, pre), hasSuffix(s, suf).
  • Literals: double-quoted strings ("Function"), true/false, numbers.

Filterable fields per command (string unless noted):

CommandFields
searchmodulePath, packagePath, synopsis, version
versionsversion, modulePath, deprecated (bool), retracted (bool), hasGoMod (bool), commitTime
packagespath, name, synopsis, isRedistributable (bool)
imported-bypath (the importing package path)
symbolsname, kind (Function/Method/Type/Variable/Constant), synopsis, parent
major-versionsmodulePath, major, version, isLatest (bool)
bash
godig symbols github.com/samber/lo --filter 'kind=="Function"' -o md
godig symbols github.com/samber/lo --filter 'kind=="Function" && hasPrefix(name,"Map")' -o md
godig versions github.com/samber/lo --filter 'hasPrefix(version,"v1.5")' -o md
godig versions github.com/samber/lo --filter 'deprecated==false && retracted==false' -o md
godig search "result option" --filter 'hasPrefix(packagePath,"github.com/samber/")' -o md

Examples

Always request Markdown output (-o md):

bash
# Overview — start here (compact, one call)
godig overview github.com/samber/ro -o md

# Search
godig search "result option monad" --limit 5 -o md

# Package facets
godig package info github.com/samber/ro -o md
godig package imports github.com/samber/ro -o md
godig package doc github.com/samber/ro --format md -o md
godig package examples github.com/samber/ro --symbol Map -o md
godig package licenses github.com/samber/ro -o md

# Single symbol (token-efficient vs package-wide doc/examples)
godig symbol doc github.com/samber/lo Map -o md
godig symbol examples github.com/samber/oops OopsError.Error -o md

# Module facets
godig module info github.com/samber/ro -o md
godig module readme github.com/samber/ro -o raw
godig dependencies github.com/samber/ro -o md

# Lists (auto-paginated; --limit to cap)
godig versions github.com/samber/ro -o md
godig major-versions github.com/samber/lo -o md
godig packages github.com/samber/ro -o md
godig imported-by github.com/samber/ro --limit 20 -o md
godig symbols github.com/samber/ro --filter 'kind=="Function"' -o md

# Pin a version / set the build context
godig versions github.com/samber/ro --filter 'hasPrefix(version,"v0.3")' -o md
godig package doc github.com/samber/lo --version v1.50.0 -o md
godig symbols github.com/samber/ro --goos linux --goarch amd64 -o md

# Vulnerabilities
godig vulns github.com/samber/ro -o md

This skill is not exhaustive. godig --help and each sub-command's --help list current flags and output formats; the data mirrors what pkg.go.dev exposes.

If you encounter a bug or unexpected behavior in godig, open an issue at https://github.com/samber/godig/issues.

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Golang Pkg Go Dev AI skill do?

Golang package and module lookup via `godig`, a pkg.go.dev API client (CLI + MCP server). Use for any Go/Golang library's documentation, API signatures, symbols, usage examples, which versions exist, licenses, whether a dependency has CVEs, or who imports a package — prefer this over Context7 for any Go package or module. Read-only, no auth. Not for upgrading dependencies (→ See `samber/cc-skills-golang@golang-dependency-management` skill), choosing a library (→ See `samber/cc-skills-golang@golang-popular-libraries` skill), or local symbols and an already-used dependency's resolved source,...

Why use Golang Pkg Go Dev on TypingMind?

Because you install it once and use it with any model. Golang Pkg Go Dev is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Golang Pkg Go Dev in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/samber/cc-skills-golang/tree/main/skills/golang-pkg-go-dev. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Golang Pkg Go Dev?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Golang Pkg Go Dev?

As many as you like. As long as a model supports skills, you can use Golang Pkg Go Dev with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Golang Pkg Go Dev AI skill free?

Yes. It is published on GitHub by samber under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇