{"id":25371228,"url":"https://github.com/td99/gitdiff2docx","last_synced_at":"2026-04-30T13:34:55.780Z","repository":{"id":275997682,"uuid":"927877736","full_name":"TD99/gitdiff2docx","owner":"TD99","description":"Converts git diffs to docx.","archived":false,"fork":false,"pushed_at":"2026-03-18T20:22:33.000Z","size":109,"stargazers_count":2,"open_issues_count":2,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-03-19T09:39:00.359Z","etag":null,"topics":["docx","docx-generator","git","git-diff","github","gitlab","ipa","microsoft-word","python","word"],"latest_commit_sha":null,"homepage":"","language":"Python","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/TD99.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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-02-05T17:33:21.000Z","updated_at":"2025-11-10T20:20:38.000Z","dependencies_parsed_at":null,"dependency_job_id":"34ad72c2-072d-4af5-ae9c-85f20b080240","html_url":"https://github.com/TD99/gitdiff2docx","commit_stats":null,"previous_names":["td99/gitdiff2docx"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/TD99/gitdiff2docx","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TD99%2Fgitdiff2docx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TD99%2Fgitdiff2docx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TD99%2Fgitdiff2docx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TD99%2Fgitdiff2docx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TD99","download_url":"https://codeload.github.com/TD99/gitdiff2docx/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TD99%2Fgitdiff2docx/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32466333,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"ssl_error","status_checked_at":"2026-04-30T13:12:06.837Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["docx","docx-generator","git","git-diff","github","gitlab","ipa","microsoft-word","python","word"],"created_at":"2025-02-15T02:33:18.895Z","updated_at":"2026-04-30T13:34:55.774Z","avatar_url":"https://github.com/TD99.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GitDiff2Docx\nA Python utility that converts git diffs into formatted Word documents. The tool helps developers and teams document code changes by creating reports from git commit differences.\n\n## Features\n- Convert git diffs to formatted DOCX files\n- Multilingual support with JSON-based localization\n- Customizable fonts and styling for diff content\n- Optional line number display\n- Color-coded changes (green for additions, red for deletions, gray for context)\n- Syntax highlighting\n- Support for multiple file changes in a single report\n- Configurable defaults via config.json\n- Ignore specific files or directories using .gddignore\n- Built-in and custom themes\n\n## Installation\n1. Clone the repository\n2. Install dependencies:\n   ```bash\n   pip install -r requirements.txt\n   ```\n\n## Usage\nRun the script and follow the interactive prompts:\n```bash\npython diff_tool.py\n```\n\nThe tool will ask for:\n- Path of the target git repository\n- Source and target commit hashes (if none entered previously)\n- Path of the output DOCX file\n\nExample interaction:\n```\n\u003c Enter the target Git directory: . \n\u003c Enter the first commit hash (optional): \u003cnone\u003e \n\u003c Enter the last commit hash (optional): \u003cnone\u003e \n\u003c Enter the output .docx file path (e.g., output.docx): ./test.docx\n```\nIf no commit hashes are provided, the tool automatically compares the latest commit (HEAD) with its predecessor.\n\n## Output Format\nThe generated DOCX includes:\n- Title with commit range\n- Section for each changed file\n- Color-coded diff tables\n- Custom font styling\n- Image support\n- Syntax highlighting\n\n## Configuration\nGitDiff2Docx can be customized using a `config.json` file placed in the same directory as `diff_tool.py`.\n\n### Themes\n- Theme files are loaded from the `themes/` folder.\n- Set `\"theme\": \"\u003cname\u003e\"` in `config.json` (without `.json`).\n- Built-in themes are `classic`, `modern`, `modern-atlas`, `modern-carbon`, `modern-sand`, and `modern-dark`.\n- Add your own theme by creating `themes/\u003cyour-theme-name\u003e.json`.\n- Optional global overrides can be applied by creating `themes/_overrides.json`.\n- Overrides are deep-merged into the selected theme, so only provided subkeys are replaced.\n- Theme-level font settings are available via `font.name` and `font.size` (applies to code tables only).\n- Theme-level border settings are available via `table_borders` (`visible`, `style`, `weight_pt`, `color`, `space`).\n\n#### Creating a New Theme\nCreate a new theme template with all required fields prefilled:\n```bash\npython diff_tool.py --create-theme\n```\n\nSelect the theme in `config.json`:\n```json\n\"theme\": \"\u003cyour-theme-name\u003e\"\n```\n\n## Localization\n- The default interface and output language is German (`de`).\n- To change it, set the `language` value in your `config.json` file to a language code available in the `lang` directory.\n   - Default languages: `de` (German), `en` (English)\n- Additional languages can be added by creating new JSON files in the `lang` directory.\n   - Each file should be named according to its language code (e.g. `fr.json` for French).\n   - GitDiff2Docx automatically detects all available languages based on the JSON files present in the `lang` directory.\n\n## Ignoring Files and Directories\nYou can exclude files or directories from being included in the diff report using a `.gddignore` file located in the target repository.  \nThis file works exactly like a `.gitignore`, supporting the same syntax and matching rules.\n\n## Disclaimer\nUse this tool at your own risk. Always verify the generated reports for accuracy.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftd99%2Fgitdiff2docx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftd99%2Fgitdiff2docx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftd99%2Fgitdiff2docx/lists"}