gitnexus-pdg-query — Claude Code skill: what it does, how to install
Helps inspect control dependencies and data flow within functions via the GitNexus pdg_query tool. Useful for tracing variable definitions and discovering guard clauses.
npx skills add abhigyanpatwari/GitNexus --skill gitnexus-pdg-query -a claude-codeWhat gitnexus-pdg-query does
The skill guides coding agents through inspecting intra-procedural control and data dependencies using the GitNexus pdg_query tool. It operates over basic block edges stored in the graph database. The controls mode reveals which predicates guard specific statements and highlights early returns. The flows mode tracks variable definitions to their downstream usages within the function body.
Running queries requires indexing the repository with the --pdg flag beforehand; without it, the tool returns an empty result set with an explanatory note. Queries remain strictly intra-procedural and cannot track data across function boundaries. Every query also demands an explicit target parameter pointing to a symbol or file path, because the underlying database lacks relationship property indexing for unbounded scans.
What it helps with
- inspect predicate conditions that guard statement execution in a function
- locate early-return and throw guard clauses
- trace variable definitions to downstream reads within a function
- diagnose empty responses from the
pdg_querytool - construct Cypher queries for control dependence edges without full table scans
Example prompts for the agent
- Check which predicates guard this return statement in the handleRequest function using pdg_query
- Trace where the config variable flows inside parseOptions using the flows mode
- Explain why pdg_query returns an empty result for the auth handler
How to install gitnexus-pdg-query
1Skills CLI (Vercel)
npx skills add abhigyanpatwari/GitNexus --skill gitnexus-pdg-query -a claude-code2Manually: put the files in place
~/.claude/skills/gitnexus-pdg-query/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/gitnexus-pdg-query/
1Skills CLI (Vercel)
npx skills add abhigyanpatwari/GitNexus --skill gitnexus-pdg-query -a codex2Manually: put the files in place
.agents/skills/gitnexus-pdg-query/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add abhigyanpatwari/GitNexus --skill gitnexus-pdg-query -a cursor2Manually: put the files in place
.cursor/skills/gitnexus-pdg-query/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install abhigyanpatwari/GitNexus gitnexus-pdg-query2Manually: put the files in place
.github/skills/gitnexus-pdg-query/SKILL.md1Skills CLI (Vercel)
npx skills add abhigyanpatwari/GitNexus --skill gitnexus-pdg-query -a gemini-cli2Platform CLI
gemini skills install https://github.com/abhigyanpatwari/GitNexus --path gitnexus-claude-plugin/skills/gitnexus-pdg-queryManually: put the files in place
.devin/skills/gitnexus-pdg-query/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add abhigyanpatwari/GitNexus --skill gitnexus-pdg-query -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
From the same set6
The whole set →Similar
Questions about gitnexus-pdg-query
How to install gitnexus-pdg-query in Claude Code?
Run the command npx skills add abhigyanpatwari/GitNexus --skill gitnexus-pdg-query -a claude-code in your terminal.
What does gitnexus-pdg-query do?
It equips the coding agent with domain knowledge to query control and data dependencies via GitNexus. The agent can inspect guarding predicates, early return clauses, and intra-function variable flows through the pdg_query tool.
Why does pdg_query return empty results?
An empty result usually occurs when the repository was indexed without the --pdg flag. Without this flag, dependency graph layers are omitted, so the tool returns an empty list accompanied by an explanatory note rather than throwing an error.