{"id":30663590,"url":"https://github.com/frandepascuali/search-pack","last_synced_at":"2025-09-02T21:05:23.035Z","repository":{"id":311827362,"uuid":"1045253457","full_name":"FranDepascuali/search-pack","owner":"FranDepascuali","description":"Search code and copy matches to clipboard for use with AI tools.","archived":false,"fork":false,"pushed_at":"2025-08-26T23:26:16.000Z","size":285,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-08-27T05:32:46.659Z","etag":null,"topics":["ai-context","ai-tools","chatgpt","claude","cli","code-search","developer-tools","gemini","grep","llm","productivity","repomix","ripgrep"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/search-pack","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FranDepascuali.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-08-26T22:08:54.000Z","updated_at":"2025-08-27T04:00:28.000Z","dependencies_parsed_at":"2025-08-27T05:35:18.806Z","dependency_job_id":"4be245ae-cac0-46a5-8bce-8abf300438ac","html_url":"https://github.com/FranDepascuali/search-pack","commit_stats":null,"previous_names":["frandepascuali/search-pack"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/FranDepascuali/search-pack","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FranDepascuali%2Fsearch-pack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FranDepascuali%2Fsearch-pack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FranDepascuali%2Fsearch-pack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FranDepascuali%2Fsearch-pack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FranDepascuali","download_url":"https://codeload.github.com/FranDepascuali/search-pack/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FranDepascuali%2Fsearch-pack/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273011006,"owners_count":25030371,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-31T02:00:09.071Z","response_time":79,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai-context","ai-tools","chatgpt","claude","cli","code-search","developer-tools","gemini","grep","llm","productivity","repomix","ripgrep"],"created_at":"2025-08-31T17:13:44.437Z","updated_at":"2025-08-31T17:13:45.114Z","avatar_url":"https://github.com/FranDepascuali.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# **search-pack**\n\nFast code search with [ripgrep](https://github.com/microsoft/vscode-ripgrep) + optional packaging for AI analysis with [repomix](https://github.com/yamadashy/repomix)\n\n## **What it does**\n\n- **Find code fast** - Literal string search powered by [vscode-ripgrep](https://github.com/microsoft/vscode-ripgrep)\n- **Package for AI** - Uses [repomix](https://github.com/yamadashy/repomix) to pack matching files to clipboard for use with any AI provider (ChatGPT, Claude, Gemini, etc.)\n\n## **Use without installing (recommended)**\n\n```bash\nnpx search-pack \u003cpattern\u003e [options]\n\n# Examples:\n## Search for any string in your codebase\nnpx search-pack \"pattern\" \n\n## Search and copy files that contain pattern\nnpx search-pack \"pattern\" --copy\n\n## Search and copy every file in a specific folder that contains pattern\nnpx search-pack \"pattern\" -f ./packages/api --copy\n```\n\n## **Example**\n\n**Basic search:**\n\n```bash\n$ npx search-pack \"performSearch\"\n# Find and list all literal matches of \"performSearch\" in your codebase\n./src/commands/search.ts:32:40:      const searchResults = await this.performSearch(pattern, folder, rgPath)\n./src/commands/search.ts:53:17:  private async performSearch(\n```\n\n**Search + pack for AI:**\n\n```bash\n$ npx search-pack \"performSearch\" --copy\n# Find all matches of \"performSearch\" and copies to clipboard the containing files for AI analysis\n./src/commands/search.ts:32:40:      const searchResults = await this.performSearch(pattern, folder, rgPath)\n./src/commands/search.ts:53:17:  private async performSearch(\n\n⠸ Running repomix...\n✔ Packing completed successfully!\n\n📈 Top 5 Files by Token Count:\n──────────────────────────────\n1.  src/commands/search.ts (1,056 tokens, 4,401 chars, 73.9%)\n\n🔎 Security Check:\n──────────────────\n✔ No suspicious files detected.\n\n📊 Pack Summary:\n────────────────\n  Total Files: 1 files\n Total Tokens: 1,429 tokens\n  Total Chars: 6,171 chars\n\n🎉 All Done!\nYour repository has been successfully packed.\n✔ Files packed and copied to clipboard!\n```\n\n## **Options**\n\n- `-c, --copy` - Pack matching files with repomix and copy to clipboard\n- `-f, --folder \u003cdir\u003e` - Directory to search (default: current)\n\n## **Global installation (optional)**\n\n```bash\nnpm install -g search-pack\n\n# Now use directly\nsearch-pack \"your pattern\"\nsp \"your pattern\"  # Short alias\n```\n\n## **How it works**\n\n1. **Search** - Uses [vscode-ripgrep](https://github.com/microsoft/vscode-ripgrep) for fast literal string matching\n2. **Display** - Shows colored results with file:line:column format\n3. **Pack** (with --copy) - Uses [repomix](https://github.com/yamadashy/repomix) to package matching files and copy to clipboard\n\n## **Features**\n\n- **Literal string search** - What you type is what you search\n- **Fast** - Powered by ripgrep, one of the fastest search tools available\n- **AI-independent** - Use with any AI provider or tool, not locked to specific IDEs or services\n- **Cross-platform** - Works on macOS, Linux, and Windows\n\n## **Why search-pack?**\n\nModern AI tools are powerful but fragmented across different providers and IDEs. Whether you use ChatGPT, Claude, Gemini, Cursor, or any other AI service, you need a consistent way to find and share code context.\n\n`search-pack` gives you that independence - find relevant code fast, package it properly with repomix, and use it with whatever AI tool you prefer. No vendor lock-in, no IDE constraints, just your code ready for any AI conversation.\n\n## **License**\n\nMIT © Francisco Depascuali\n\n## **Dependencies**\n\n- [vscode-ripgrep](https://github.com/microsoft/vscode-ripgrep) - Ripgrep bundled for Node.js\n- [repomix](https://github.com/yamadashy/repomix) - File packaging for AI context\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrandepascuali%2Fsearch-pack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffrandepascuali%2Fsearch-pack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrandepascuali%2Fsearch-pack/lists"}