MCPcopy Index your code
hub / github.com/KOBA789/gh-sql

github.com/KOBA789/gh-sql @v0.4.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.4.0 ↗ · + Follow
66 symbols 100 edges 7 files 0 documented · 0%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

gh-sql: Query GitHub Projects (beta) with SQL

Installation

gh extension install KOBA789/gh-sql

Features

  • SELECT items
  • DELETE items
  • UPDATE item fields
  • You can not modify Title, Assignees, Labels, Milestone, or Repository

Usage

USAGE:
    gh-sql [OPTIONS] <OWNER> <PROJECT_NUMBER>

FLAGS:
    -h, --help       Prints help information
    -V, --version    Prints version information

OPTIONS:
    -e, --execute <execute>    SQL statement to execute
    -o, --output <output>      "table", "json" or these initial [default: table]

ARGS:
    <OWNER>
    <PROJECT_NUMBER>

eg. JSON output in non-interactive execution

  • -oj: output as json
  • -e: non-interactive mode
gh sql YOUR_NAME YOUR_PROJECT_NUMBER -oj -e 'select * from items;'

eg. Make task list in markdown

Of course, you can also pipe it to jq.

gh sql YOUR_NAME YOUR_PROJECT_NUMBER -oj -e 'select * from items where Repository is not null;' | \
    jq -r '"- " + .Repository + "#" + (.Issue | tostring)'

Extension points exported contracts — how you extend this code

IntoQuadRow (Interface)
(no doc) [2 implementers]
src/storage.rs

Core symbols most depended-on inside this repo

graphql
called by 4
src/gh.rs
print
called by 3
src/output.rs
run
called by 2
src/batch.rs
items_schema
called by 2
src/storage.rs
fetch_data
called by 2
src/storage.rs
print_as_table
called by 1
src/output.rs
print_value_in_table
called by 1
src/output.rs
print_as_json
called by 1
src/output.rs

Shape

Method 38
Class 16
Function 8
Enum 3
Interface 1

Languages

Rust100%

Modules by API surface

src/storage.rs40 symbols
src/prompt.rs8 symbols
src/output.rs7 symbols
src/gh.rs4 symbols
src/batch.rs4 symbols
src/main.rs2 symbols
build.rs1 symbols

For agents

$ claude mcp add gh-sql \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact