Repomix CLI命令大全所有参数选项详解【免费下载链接】repomix Repomix (formerly Repopack) is a powerful tool that packs your entire repository into a single, AI-friendly file. Perfect for when you need to feed your codebase to Large Language Models (LLMs) or other AI tools like Claude, ChatGPT, DeepSeek, Perplexity, Gemini, Gemma, Llama, Grok, and more.项目地址: https://gitcode.com/GitHub_Trending/rep/repomixRepomix是一个强大的AI代码仓库打包工具能够将整个代码库打包成单个AI友好文件。本文将详细介绍Repomix CLI的所有命令参数帮助您充分利用这个工具的强大功能。无论您是初次使用Repomix的新手还是想要深入了解高级功能的高级用户这篇完整指南都将为您提供全面的CLI命令参考。 基础命令与安装快速开始无需安装直接使用npx运行最新版本npx repomixlatest全局安装如需频繁使用建议全局安装npm install -g repomix安装后您可以直接在任何目录中使用repomix命令。 基础选项版本信息查看Repomix版本repomix --version初始化配置创建默认配置文件repomix --init创建全局配置文件存储在用户主目录repomix --init --global帮助信息查看所有可用选项repomix --help 输入输出选项输出控制基本输出- 将结果输出到指定文件repomix -o output.xml repomix --output custom-output.md标准输出- 将结果直接输出到终端repomix --stdout repomix --stdout output.txt管道处理- 与其他命令结合使用repomix --stdout | llm 请分析这个代码库输出到剪贴板- 自动复制到系统剪贴板repomix --copy输出格式选择不同的输出格式repomix --style xml # 默认格式结构化最好 repomix --style markdown # Markdown格式 repomix --style json # JSON格式 repomix --style plain # 纯文本格式输出优化选项显示行号- 在输出中显示行号repomix --output-show-line-numbers自定义头部文本- 添加自定义头部信息repomix --header-text 项目分析报告 - 生成于 $(date)使用指令文件- 包含自定义指令repomix --instruction-file-path instructions.md 文件选择与过滤包含模式只包含特定文件repomix --include src/**/*.ts,**/*.md repomix --include *.js,*.ts,*.jsx,*.tsx排除模式排除特定文件repomix --ignore **/*.test.js,docs/** repomix --ignore node_modules,dist,build忽略文件控制禁用.gitignore- 不使用.gitignore规则repomix --no-gitignore禁用.ignore文件- 不使用.ignore规则repomix --no-dot-ignore禁用默认模式- 不使用内置忽略模式repomix --no-default-patterns标准输入模式从标准输入读取文件列表find src -name *.ts -type f | repomix --stdin git ls-files *.ts | repomix --stdin rg -l TODO **/*.ts | repomix --stdin 高级处理选项代码压缩使用Tree-sitter提取关键代码结构repomix --compress注释和空行处理移除注释repomix --remove-comments移除空行repomix --remove-empty-lines大文件处理截断Base64数据repomix --truncate-base64分割输出文件- 按大小分割输出repomix --split-output 1mb repomix --split-output 500kb repomix --split-output 2.5mb 仓库分析与统计目录结构选项包含空目录repomix --include-empty-directories显示完整目录结构repomix --include-full-directory-structureGit集成功能包含差异信息- 显示工作区和暂存区的更改repomix --include-diffs包含提交历史- 显示Git提交历史repomix --include-logs repomix --include-logs --include-logs-count 10禁用Git排序- 不按更改频率排序文件repomix --no-git-sort-by-changes令牌计数令牌计数树- 显示文件令牌统计repomix --token-count-tree repomix --token-count-tree 1000 # 只显示1000令牌的文件令牌编码设置repomix --token-count-encoding o200k_base # GPT-4o默认 repomix --token-count-encoding cl100k_base # GPT-3.5/4文件摘要禁用文件摘要repomix --no-file-summary禁用目录结构repomix --no-directory-structure仅元数据模式- 不包含文件内容repomix --no-files 远程仓库处理远程仓库打包基本远程打包repomix --remote https://github.com/yamadashy/repomix repomix --remote yamadashy/repomix指定分支或标签repomix --remote https://github.com/yamadashy/repomix --remote-branch main repomix --remote https://github.com/yamadashy/repomix --remote-branch v1.0.0指定特定提交repomix --remote https://github.com/yamadashy/repomix --remote-branch 935b695信任远程配置- 加载远程仓库的配置文件repomix --remote https://github.com/user/repo --remote-trust-config复杂远程URL支持支持各种GitHub URL格式repomix --remote https://github.com/yamadashy/repomix/tree/main repomix --remote https://github.com/yamadashy/repomix/commit/836abcd7335137228ad77feb28655d85712680f1 安全选项安全检查禁用安全检查- 跳过敏感数据扫描repomix --no-security-check AI技能生成实验性功能生成Claude Agent技能基本技能生成repomix --skill-generate repomix --skill-generate my-project-reference指定输出目录repomix --skill-generate --skill-output ./my-skills强制覆盖- 跳过确认提示repomix --skill-generate --skill-output ./my-skills --force远程仓库技能生成repomix --remote user/repo --skill-generate repomix --remote user/repo --skill-generate my-skill --skill-output ./output --force技能生成与过滤结合生成特定文件的技能repomix --skill-generate --include src/**/*.ts --ignore **/*.test.ts repomix --skill-generate --compress️ MCP服务器模式运行MCP服务器启动Model Context Protocol服务器repomix --mcp 性能与调试选项日志级别控制详细日志- 显示调试信息repomix --verbose静默模式- 只显示错误repomix --quiet文件统计显示最大文件- 指定显示的最大文件数量repomix --top-files-len 20 实用组合示例实际使用场景完整项目分析repomix --include src/**/* --ignore **/*.test.* --compress --include-diffs --include-logsAI优化输出repomix --compress --remove-comments --remove-empty-lines --style markdown安全扫描模式repomix --no-security-check --verbose --token-count-tree批量处理脚本#!/bin/bash for repo in repo1 repo2 repo3; do repomix --remote $repo --output ${repo}-analysis.xml --quiet done⚙️ 配置文件使用自定义配置文件使用自定义配置文件repomix --config custom-config.json配置文件位置Repomix按以下顺序查找配置文件命令行指定的--config文件当前目录的repomix.config.json用户主目录的.repomix/config.json Docker使用Docker容器运行使用Docker运行Repomixdocker run -v $(pwd):/app -it --rm ghcr.io/yamadashy/repomix docker run -v ./output:/app -it --rm ghcr.io/yamadashy/repomix --remote https://github.com/yamadashy/repomix 故障排除与提示常见问题解决权限问题- 确保对目标目录有读取权限内存不足- 使用--compress减少内存使用输出文件过大- 使用--split-output分割文件网络问题- 使用--verbose查看详细日志性能优化建议使用--compress减少输出大小使用--ignore排除不必要文件使用--quiet减少日志输出使用--no-files只生成元数据 总结与最佳实践Repomix CLI提供了丰富的选项来满足不同场景的需求。通过合理组合这些参数您可以优化AI处理- 使用--compress和--remove-comments提高安全性- 启用安全检查排除敏感文件增强可读性- 使用--output-show-line-numbers和--style markdown批量处理- 结合--stdin和管道操作远程分析- 使用--remote处理GitHub仓库掌握这些CLI命令将帮助您更高效地使用Repomix进行代码库分析和AI集成。无论是个人项目还是企业级应用Repomix都能为您提供强大的代码打包和分析能力。【免费下载链接】repomix Repomix (formerly Repopack) is a powerful tool that packs your entire repository into a single, AI-friendly file. Perfect for when you need to feed your codebase to Large Language Models (LLMs) or other AI tools like Claude, ChatGPT, DeepSeek, Perplexity, Gemini, Gemma, Llama, Grok, and more.项目地址: https://gitcode.com/GitHub_Trending/rep/repomix创作声明:本文部分内容由AI辅助生成(AIGC),仅供参考
Repomix CLI命令大全:所有参数选项详解
Repomix CLI命令大全所有参数选项详解【免费下载链接】repomix Repomix (formerly Repopack) is a powerful tool that packs your entire repository into a single, AI-friendly file. Perfect for when you need to feed your codebase to Large Language Models (LLMs) or other AI tools like Claude, ChatGPT, DeepSeek, Perplexity, Gemini, Gemma, Llama, Grok, and more.项目地址: https://gitcode.com/GitHub_Trending/rep/repomixRepomix是一个强大的AI代码仓库打包工具能够将整个代码库打包成单个AI友好文件。本文将详细介绍Repomix CLI的所有命令参数帮助您充分利用这个工具的强大功能。无论您是初次使用Repomix的新手还是想要深入了解高级功能的高级用户这篇完整指南都将为您提供全面的CLI命令参考。 基础命令与安装快速开始无需安装直接使用npx运行最新版本npx repomixlatest全局安装如需频繁使用建议全局安装npm install -g repomix安装后您可以直接在任何目录中使用repomix命令。 基础选项版本信息查看Repomix版本repomix --version初始化配置创建默认配置文件repomix --init创建全局配置文件存储在用户主目录repomix --init --global帮助信息查看所有可用选项repomix --help 输入输出选项输出控制基本输出- 将结果输出到指定文件repomix -o output.xml repomix --output custom-output.md标准输出- 将结果直接输出到终端repomix --stdout repomix --stdout output.txt管道处理- 与其他命令结合使用repomix --stdout | llm 请分析这个代码库输出到剪贴板- 自动复制到系统剪贴板repomix --copy输出格式选择不同的输出格式repomix --style xml # 默认格式结构化最好 repomix --style markdown # Markdown格式 repomix --style json # JSON格式 repomix --style plain # 纯文本格式输出优化选项显示行号- 在输出中显示行号repomix --output-show-line-numbers自定义头部文本- 添加自定义头部信息repomix --header-text 项目分析报告 - 生成于 $(date)使用指令文件- 包含自定义指令repomix --instruction-file-path instructions.md 文件选择与过滤包含模式只包含特定文件repomix --include src/**/*.ts,**/*.md repomix --include *.js,*.ts,*.jsx,*.tsx排除模式排除特定文件repomix --ignore **/*.test.js,docs/** repomix --ignore node_modules,dist,build忽略文件控制禁用.gitignore- 不使用.gitignore规则repomix --no-gitignore禁用.ignore文件- 不使用.ignore规则repomix --no-dot-ignore禁用默认模式- 不使用内置忽略模式repomix --no-default-patterns标准输入模式从标准输入读取文件列表find src -name *.ts -type f | repomix --stdin git ls-files *.ts | repomix --stdin rg -l TODO **/*.ts | repomix --stdin 高级处理选项代码压缩使用Tree-sitter提取关键代码结构repomix --compress注释和空行处理移除注释repomix --remove-comments移除空行repomix --remove-empty-lines大文件处理截断Base64数据repomix --truncate-base64分割输出文件- 按大小分割输出repomix --split-output 1mb repomix --split-output 500kb repomix --split-output 2.5mb 仓库分析与统计目录结构选项包含空目录repomix --include-empty-directories显示完整目录结构repomix --include-full-directory-structureGit集成功能包含差异信息- 显示工作区和暂存区的更改repomix --include-diffs包含提交历史- 显示Git提交历史repomix --include-logs repomix --include-logs --include-logs-count 10禁用Git排序- 不按更改频率排序文件repomix --no-git-sort-by-changes令牌计数令牌计数树- 显示文件令牌统计repomix --token-count-tree repomix --token-count-tree 1000 # 只显示1000令牌的文件令牌编码设置repomix --token-count-encoding o200k_base # GPT-4o默认 repomix --token-count-encoding cl100k_base # GPT-3.5/4文件摘要禁用文件摘要repomix --no-file-summary禁用目录结构repomix --no-directory-structure仅元数据模式- 不包含文件内容repomix --no-files 远程仓库处理远程仓库打包基本远程打包repomix --remote https://github.com/yamadashy/repomix repomix --remote yamadashy/repomix指定分支或标签repomix --remote https://github.com/yamadashy/repomix --remote-branch main repomix --remote https://github.com/yamadashy/repomix --remote-branch v1.0.0指定特定提交repomix --remote https://github.com/yamadashy/repomix --remote-branch 935b695信任远程配置- 加载远程仓库的配置文件repomix --remote https://github.com/user/repo --remote-trust-config复杂远程URL支持支持各种GitHub URL格式repomix --remote https://github.com/yamadashy/repomix/tree/main repomix --remote https://github.com/yamadashy/repomix/commit/836abcd7335137228ad77feb28655d85712680f1 安全选项安全检查禁用安全检查- 跳过敏感数据扫描repomix --no-security-check AI技能生成实验性功能生成Claude Agent技能基本技能生成repomix --skill-generate repomix --skill-generate my-project-reference指定输出目录repomix --skill-generate --skill-output ./my-skills强制覆盖- 跳过确认提示repomix --skill-generate --skill-output ./my-skills --force远程仓库技能生成repomix --remote user/repo --skill-generate repomix --remote user/repo --skill-generate my-skill --skill-output ./output --force技能生成与过滤结合生成特定文件的技能repomix --skill-generate --include src/**/*.ts --ignore **/*.test.ts repomix --skill-generate --compress️ MCP服务器模式运行MCP服务器启动Model Context Protocol服务器repomix --mcp 性能与调试选项日志级别控制详细日志- 显示调试信息repomix --verbose静默模式- 只显示错误repomix --quiet文件统计显示最大文件- 指定显示的最大文件数量repomix --top-files-len 20 实用组合示例实际使用场景完整项目分析repomix --include src/**/* --ignore **/*.test.* --compress --include-diffs --include-logsAI优化输出repomix --compress --remove-comments --remove-empty-lines --style markdown安全扫描模式repomix --no-security-check --verbose --token-count-tree批量处理脚本#!/bin/bash for repo in repo1 repo2 repo3; do repomix --remote $repo --output ${repo}-analysis.xml --quiet done⚙️ 配置文件使用自定义配置文件使用自定义配置文件repomix --config custom-config.json配置文件位置Repomix按以下顺序查找配置文件命令行指定的--config文件当前目录的repomix.config.json用户主目录的.repomix/config.json Docker使用Docker容器运行使用Docker运行Repomixdocker run -v $(pwd):/app -it --rm ghcr.io/yamadashy/repomix docker run -v ./output:/app -it --rm ghcr.io/yamadashy/repomix --remote https://github.com/yamadashy/repomix 故障排除与提示常见问题解决权限问题- 确保对目标目录有读取权限内存不足- 使用--compress减少内存使用输出文件过大- 使用--split-output分割文件网络问题- 使用--verbose查看详细日志性能优化建议使用--compress减少输出大小使用--ignore排除不必要文件使用--quiet减少日志输出使用--no-files只生成元数据 总结与最佳实践Repomix CLI提供了丰富的选项来满足不同场景的需求。通过合理组合这些参数您可以优化AI处理- 使用--compress和--remove-comments提高安全性- 启用安全检查排除敏感文件增强可读性- 使用--output-show-line-numbers和--style markdown批量处理- 结合--stdin和管道操作远程分析- 使用--remote处理GitHub仓库掌握这些CLI命令将帮助您更高效地使用Repomix进行代码库分析和AI集成。无论是个人项目还是企业级应用Repomix都能为您提供强大的代码打包和分析能力。【免费下载链接】repomix Repomix (formerly Repopack) is a powerful tool that packs your entire repository into a single, AI-friendly file. Perfect for when you need to feed your codebase to Large Language Models (LLMs) or other AI tools like Claude, ChatGPT, DeepSeek, Perplexity, Gemini, Gemma, Llama, Grok, and more.项目地址: https://gitcode.com/GitHub_Trending/rep/repomix创作声明:本文部分内容由AI辅助生成(AIGC),仅供参考