gh-sql: Query GitHub Projects (beta) with SQL
gh extension install KOBA789/gh-sql
SELECT itemsDELETE itemsUPDATE item fieldsTitle, Assignees, Labels, Milestone, or RepositoryUSAGE:
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>
-oj: output as json-e: non-interactive modegh sql YOUR_NAME YOUR_PROJECT_NUMBER -oj -e 'select * from items;'
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)'
$ claude mcp add gh-sql \
-- python -m otcore.mcp_server <graph>