Search GitHub - find code, issues, users, and repositories across GitHub using gh CLI
Search GitHub for code, issues, PRs, repositories, and users using gh CLI. Use when you need to find specific code patterns, track issues, discover projects, or locate developers across GitHub.
/plugin marketplace add Nice-Wolf-Studio/agent-github-skills/plugin install nice-wolf-studio-github-skills@Nice-Wolf-Studio/agent-github-skillsThis skill inherits all available tools. When active, it can use any tool Claude has access to.
This skill provides comprehensive search capabilities across GitHub including searching for code, issues, pull requests, repositories, and users.
Search for code across GitHub repositories.
Search for issues and PRs with advanced filters.
Find repositories matching specific criteria.
Find GitHub users and organizations.
Basic code search:
gh search code "function authenticate" --limit 20
Search in specific language:
gh search code "async function" --language javascript --limit 30
Search in specific repository:
gh search code "TODO" --repo owner/repo-name
Search in organization:
gh search code "API_KEY" --owner myorg
Search with extension filter:
gh search code "class.*Component" --extension tsx
Search by file path:
gh search code "config" --path "src/config"
Complex code search:
gh search code "useState" --language typescript --extension tsx --owner facebook
Search with size filter:
gh search code "import React" --size ">1000"
JSON output for processing:
gh search code "security vulnerability" --json path,repository,url --jq '.[] | {file: .path, repo: .repository.fullName}'
Search all issues:
gh search issues "memory leak" --limit 30
Search in specific repository:
gh search issues "bug" --repo owner/repo-name
Search open issues only:
gh search issues "crash" --state open
Search closed issues:
gh search issues "fixed" --state closed
Search by label:
gh search issues "bug" --label "critical"
Multiple labels:
gh search issues "" --label "bug" --label "security"
Search by author:
gh search issues "feature" --author username
Search by assignee:
gh search issues "" --assignee username
Search in organization:
gh search issues "todo" --owner myorg
Search by date:
gh search issues "bug" --created ">2025-01-01"
gh search issues "feature" --updated "<2025-01-01"
Search by comments count:
gh search issues "help wanted" --comments ">10"
Search PRs only:
gh search prs "feat:" --state open --limit 20
Complex issue search:
gh search issues "is:open is:issue label:bug assignee:@me"
Search with reactions:
gh search issues "good first issue" --reactions ">5"
JSON output:
gh search issues "security" --json number,title,state,url --jq '.[] | "\(.number): \(.title)"'
Basic repository search:
gh search repos "machine learning" --limit 20
Search by language:
gh search repos "web framework" --language python
Search by stars:
gh search repos "react" --stars ">10000"
Search by forks:
gh search repos "kubernetes" --forks ">1000"
Search by size (KB):
gh search repos "starter template" --size "<1000"
Search in organization:
gh search repos "" --owner microsoft
Search by topic:
gh search repos "topic:docker topic:kubernetes"
Search archived repositories:
gh search repos "old-project" --archived
Search by license:
gh search repos "utility library" --license mit
Search by creation date:
gh search repos "created:>2025-01-01"
Search by last update:
gh search repos "updated:>2025-01-01" --stars ">100"
Search by number of followers:
gh search repos "followers:>1000"
Complex repository search:
gh search repos "stars:>5000 language:python topic:machine-learning"
JSON output:
gh search repos "awesome" --json name,owner,stars,url --jq '.[] | "\(.owner.login)/\(.name) - \(.stars) stars"'
Basic user search:
gh search users "john doe" --limit 10
Search by location:
gh search users "location:seattle"
Search by language:
gh search users "language:python"
Search by followers:
gh search users "followers:>1000"
Search by repositories:
gh search users "repos:>50"
Search organizations:
gh search users "type:org"
Search individual users:
gh search users "type:user"
Search by creation date:
gh search users "created:>2020-01-01"
Complex user search:
gh search users "location:california language:javascript followers:>100"
JSON output:
gh search users "location:london" --json login,name,url --jq '.[] | "\(.login): \(.name)"'
Boolean operators:
# AND (default)
gh search code "class AND function"
# OR
gh search code "bug OR error"
# NOT
gh search code "NOT deprecated"
Exact phrase matching:
gh search code '"exact phrase here"'
Wildcards:
gh search repos "test*"
Range queries:
gh search repos "stars:10..50"
gh search issues "created:2025-01-01..2025-12-31"
Qualifiers:
# Search code
gh search code "repo:owner/name path:src/ language:js"
# Search issues
gh search issues "is:open is:issue label:bug assignee:@me"
# Search PRs
gh search prs "is:pr is:open review:approved"
# Search repos
gh search repos "stars:>1000 forks:>500 language:python"
# Search for exposed API keys
gh search code "API_KEY" --language javascript
# Search for TODO security items
gh search code "TODO.*security" --owner myorg
# Find hardcoded passwords
gh search code "password.*=.*['\"]" --language python
# Search for SQL injection vulnerabilities
gh search code "query.*=.*+.*req\." --language javascript
# Find usage examples
gh search code "import MyLibrary" --language typescript
# Find configuration examples
gh search code "filename:config.yml" --owner popular-org
# Find test examples
gh search code "describe.*test" --path "test/" --language javascript
# Find active projects
gh search repos "stars:>100 pushed:>2025-01-01" --language rust
# Find good first issues
gh search issues "label:good-first-issue state:open"
# Find projects needing help
gh search issues "label:help-wanted state:open" --sort comments
# Find trending repositories
gh search repos "created:>2025-01-01" --sort stars
# Find similar projects
gh search repos "web framework language:python stars:>1000"
# Find what competitors are building
gh search repos "owner:competitor-org"
# Track competitor issues
gh search issues "org:competitor-org is:open"
# See popular forks
gh search repos "fork:true" --sort stars
# Find your open issues
gh search issues "assignee:@me state:open"
# Find PRs needing review
gh search prs "review-requested:@me state:open"
# Find team's open PRs
gh search prs "team:myorg/myteam state:open"
# Find stale issues
gh search issues "updated:<2024-01-01 state:open"
For repositories:
--sort stars: Sort by star count--sort forks: Sort by fork count--sort updated: Sort by last update--sort help-wanted-issues: Sort by help wanted issuesgh search repos "javascript framework" --sort stars --order desc
For issues:
--sort comments: Sort by comment count--sort created: Sort by creation date--sort updated: Sort by update date--sort reactions: Sort by reaction countgh search issues "bug" --sort comments --order desc
For code:
--sort indexed: Sort by when indexed (default)Limit results:
gh search repos "python" --limit 100
Get more results (max 100):
gh search code "function" --limit 100
Basic JSON:
gh search repos "docker" --json name,description,stars
Pipe to jq for processing:
gh search repos "kubernetes" --json name,stars,url \
| jq '.[] | select(.stars > 1000) | {name, stars}'
Extract specific fields:
gh search issues "bug" --json number,title,state --jq '.[] | "\(.number): \(.title) [\(.state)]"'
# Check rate limit status
gh api rate_limit
# If rate limited, wait or authenticate
gh auth login
# Verify query syntax
gh search repos "test" --limit 1
# Try broader query
gh search repos "test*" --limit 10
# Try more specific query
gh search code "function" --repo owner/specific-repo
# Use fewer qualifiers
--limit to get manageable result sets--sort to find most relevant resultsrepository-management after finding repos to clone or forkissue-management to work with found issuespull-request-management for found PRscode-review to review found codeCreating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems. Create original algorithmic art rather than copying existing artists' work to avoid copyright violations.
Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply.
Create beautiful visual art in .png and .pdf documents using design philosophy. You should use this skill when the user asks to create a poster, piece of art, design, or other static piece. Create original visual designs, never copying existing artists' work to avoid copyright violations.