@devlensio/skill
v0.2.1
Published
Installer for the DevLens Agent Skill — adds the /devlens skill (architecture, diagrams, security analysis, impact, summaries) to Claude Code, Cursor, and other AI coding tools.
Maintainers
Readme
@devlensio/skill
Installs the DevLens Agent Skill (/devlens) into your AI coding tool. The skill teaches the agent to drive the DevLens CLI — querying a precomputed code graph (nodes, typed edges, technical/business/security summaries) instead of grepping and reading whole files.
Install
# Install into the AI tools detected in this project (defaults to Claude Code if none found)
npx @devlensio/skill install
# Force a specific tool
npx @devlensio/skill install --harness=cursor
# Install into your home directory instead of the current project
npx @devlensio/skill install --global
# Re-copy after an update / overwrite an existing install
npx @devlensio/skill update # or: install --force
# See whether your install is up to date
npx @devlensio/skill checkRequires the DevLens CLI itself:
npm install -g @devlensio/cli. Behind a corporate proxy? setNODE_EXTRA_CA_CERTSto your org root CA.
After installing, reload your tool and type /devlens — e.g. /devlens architecture, /devlens security-analysis, /devlens diagram.
Supported tools
| Harness | Project skills dir | Global (--global) dir |
| :-- | :-- | :-- |
| Claude Code | .claude/skills/devlens/ | ~/.claude/skills/devlens/ |
| Cursor | .cursor/skills/devlens/ | ~/.cursor/skills/devlens/ |
| Kilo Code | .kilo/skills/devlens/ | ~/.kilocode/skills/devlens/ |
| opencode | .opencode/skills/devlens/ | ~/.config/opencode/skills/devlens/ |
| pi | .agents/skills/devlens/ | ~/.pi/agent/skills/devlens/ |
Without --harness, the installer auto-detects which tools are in use from their marker dirs (.claude, .cursor, .kilo/.kilocode, .opencode, .pi/.agents) and installs to each. (.agents/skills/ is a shared convention also read by Kilo Code and opencode.)
Claude Code users can alternatively install via the plugin marketplace:
/plugin marketplace add devlensio/devlensOSS
/plugin install devlens@devlensioFor maintainers
How this package is built
The skill content has one source of truth: plugins/devlens/skills/devlens/ in this repo (the Claude plugin). This installer package does not keep its own copy in git. Instead, a copy is generated at publish time:
scripts/bundle-skill.mjscopies that source skill intopackages/skill-installer/skill/.- It runs automatically on the
prepacknpm lifecycle hook (i.e. beforenpm pack/npm publish). skill/is gitignored — it only exists transiently during a publish.
This is why the package can't just reference ../../plugins/...: an npm tarball can only contain files inside the package directory, so the skill must be bundled in.
package.json fields that matter
bin({ "skill": "bin/skill.mjs" }) — declares the executable. This is what makesnpx @devlensio/skill …resolve to and runbin/skill.mjs.files(["bin/", "skill/"]) — the whitelist of what ships in the tarball. Paths are relative to thispackage.json, sobin/=packages/skill-installer/bin/andskill/=packages/skill-installer/skill/.scripts/is intentionally not listed —bundle-skill.mjsis a build-time tool and must not ship.prepackscript — runsbundle-skill.mjsto populateskill/before packing.
So bin/skill.mjs runs on the user's machine; scripts/bundle-skill.mjs runs on the publisher's machine. Same package, two roles.
Releasing a new version
The skill product is versioned independently of the @devlensio/cli. The version lives in two files that must stay identical:
packages/skill-installer/package.json→ drivesnpx @devlensio/skill updateplugins/devlens/.claude-plugin/plugin.json→ gates Claude/plugin update
Stamp both at once from the repo root:
node scripts/set-skill-version.mjs 0.2.0Then publish each channel:
# npx installer
cd packages/skill-installer && npm publish # prepack rebundles skill/; first publish: --access public + 2FA
# Claude plugin
git commit -am "skill 0.2.0" && git push # users update via /plugin updateDo not add these versions to the CLI's
scripts/set-version.mjs— keeping them separate ensures a CLI release never bumps the skill.
