| Crates.io | git-seek |
| lib.rs | git-seek |
| version | 1.3.0 |
| created_at | 2025-12-26 11:10:18.429359+00 |
| updated_at | 2025-12-30 06:25:28.033312+00 |
| description | Query Git repositories using Trustfall's GraphQL-like syntax |
| homepage | https://github.com/starfy84/git-seek |
| repository | https://github.com/starfy84/git-seek |
| max_upload_size | |
| id | 2005588 |
| size | 47,330 |
A command-line tool for querying Git repositories using Trustfall's GraphQL-like syntax.
cargo install git-seek
git clone git@github.com:starfy84/git-seek.git
cd git-seek
cargo build --release -p git-seek
# Query repository name
git-seek --query '{repository {name @output}}'
# Query all branches
git-seek --query '{repository {branches {name @output}}}'
# Query commits with their messages
git-seek --query '{repository {commits {hash @output message @output}}}'
You can provide queries in three ways:
Inline query (using --query or -q):
git-seek --query '{repository {name @output}}'
From file (using --file or -f):
git-seek --file my-query.graphql
Via stdin (pipe input):
echo '{repository {name @output}}' | git-seek
Use variables in your queries with --var:
git-seek --query '{repository {name @output}}' --var repo_name=my-repo
Control the output format with --format:
raw (default) - Raw debug outputjson - Pretty-printed JSONtable - Human-readable table# JSON output
git-seek --query '{repository {branches {name @output}}}' --format json
# Table output
git-seek --query '{repository {commits {hash @output message @output}}}' --format table
git-seek --query '{
repository {
name @output
}
}' --format json
git-seek --query '{
repository {
branches {
name @output
commit {
hash @output
message @output
}
}
}
}' --format table
git-seek --query '{
repository {
commits {
hash @output
message @output
}
}
}' --format table
# Get only the last 5 commits
git-seek --query '{
repository {
commits(limit: 5) {
hash @output
message @output
author @output
}
}
}' --format table
The tool provides helpful error messages:
# Run tests
cargo test -p git-seek
# Build in debug mode
cargo build -p git-seek
# Run with debug output
RUST_LOG=debug git-seek --query '{repository {name @output}}'
trustfall_git_adapter - The Git adapter libraryclap - Command-line argument parsinggit2 - Git repository accessserde_json - JSON serializationcomfy-table - Table formattinganyhow - Error handlingBSD-3-Clause