repo2md is a command-line tool for generating Markdown files that represent the directory structure and code content of a specified Git repository or local directory.
Make sure you have Go installed on your system. Then, install repo2md using the following command:
go install github.com/iamdanielyin/repo2md@latestGenerate a Markdown file for a local directory:
repo2md /path/to/your/local/repoGenerate a Markdown file for a remote Git repository:
repo2md https://github.com/username/repo.gitBy default, the Markdown file will be named repo_structure.md.
-o <output-file>: Specify the output Markdown file name (default isrepo_structure.md).-h,--help: Display help information.
Assume you have a local Git repository /path/to/your/local/repo. Use the following command to generate a Markdown file:
repo2md /path/to/your/local/repoThe generated Markdown file will include the directory structure and content of all code files in the repository.
- The generated Markdown file includes the directory structure and content of all code files in the Git repository or local directory. Make sure you have read permissions for these files.
- If the Git repository contains a large number of files or large files, the generated Markdown file may be large.
If you encounter any issues or have any suggestions while using repo2md, please file an issue on GitHub Issues.
This README provides comprehensive installation instructions, usage details, options, examples, notes, and support information to help users understand how to install and use the repo2md tool.