{"id":22542621,"url":"https://github.com/denismurphy/code2llm","last_synced_at":"2026-02-09T02:31:52.476Z","repository":{"id":265731946,"uuid":"866976435","full_name":"denismurphy/code2llm","owner":"denismurphy","description":"Bash script designed to capture both the structure and content of your code into a single file for processing by an LLM.","archived":false,"fork":false,"pushed_at":"2024-10-04T14:12:55.000Z","size":7,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-11T10:39:23.178Z","etag":null,"topics":["bash","filestructure","gpt","llm","single-file","tree"],"latest_commit_sha":null,"homepage":"","language":"Shell","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/denismurphy.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}},"created_at":"2024-10-03T08:22:06.000Z","updated_at":"2025-07-04T05:00:11.000Z","dependencies_parsed_at":"2024-12-06T07:46:02.691Z","dependency_job_id":null,"html_url":"https://github.com/denismurphy/code2llm","commit_stats":null,"previous_names":["denismurphy/code2llm"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/denismurphy/code2llm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denismurphy%2Fcode2llm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denismurphy%2Fcode2llm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denismurphy%2Fcode2llm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denismurphy%2Fcode2llm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/denismurphy","download_url":"https://codeload.github.com/denismurphy/code2llm/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/denismurphy%2Fcode2llm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29254316,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-09T01:52:29.835Z","status":"online","status_checked_at":"2026-02-09T02:00:09.501Z","response_time":56,"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":["bash","filestructure","gpt","llm","single-file","tree"],"created_at":"2024-12-07T13:11:36.657Z","updated_at":"2026-02-09T02:31:52.471Z","avatar_url":"https://github.com/denismurphy.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Code2LLM\n\nCode2LLM is a bash script designed to capture both the structure and content of your code into a single file for processing by an LLM.\n\n## Features\n\n- Generates a tree structure of your project directory\n- Outputs the content of each file with the filename as a comment\n- Customizable depth for directory structure (default: 5 levels)\n- Easy to use with any project directory\n\n## Installation\n\n1. Clone this repository:\n   ```\n   git clone https://github.com/yourusername/code2llm.git\n   ```\n\n2. Navigate to the cloned directory:\n   ```\n   cd code2llm\n   ```\n\n3. Make the script executable:\n   ```\n   chmod +x code2llm.sh\n   ```\n\n## Usage\n\nRun the script with your project directory as an argument:\n\n```\n./code2llm.sh /path/to/your/project\n```\n\nThis will output the directory structure and the contents of each file in the specified project directory.\n\n## Output Format\n\nThe script generates output in the following format:\n\n1. Directory structure (up to 5 levels deep by default)\n2. For each file:\n   - Filename as a comment\n   - File contents\n   - Separator between files\n\nExample output:\n\n```\nDirectory Structure:\n.\n├── src\n│   ├── main.py\n│   └── utils.py\n└── tests\n    └── test_main.py\n\nFile Contents:\n# File: ./src/main.py\n------------------------\ndef main():\n    print(\"Hello, World!\")\n\nif __name__ == \"__main__\":\n    main()\n------------------------\n\n# File: ./src/utils.py\n------------------------\ndef helper_function():\n    return \"I'm helping!\"\n------------------------\n\n...\n```\n\n## Customization\n\nYou can modify the script to:\n\n- Change the depth of the directory structure by altering the `-L` option in the `tree` command\n- Add filters for specific file types\n- Exclude certain directories or files\n- Implement size limits for large files\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdenismurphy%2Fcode2llm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdenismurphy%2Fcode2llm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdenismurphy%2Fcode2llm/lists"}