{"id":31359375,"url":"https://github.com/perbu/gitsummarize","last_synced_at":"2026-07-13T05:01:58.673Z","repository":{"id":303375412,"uuid":"1015268509","full_name":"perbu/gitsummarize","owner":"perbu","description":"Summarize a git repo per day based on git commits","archived":false,"fork":false,"pushed_at":"2025-07-07T09:19:42.000Z","size":41,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-26T23:37:33.841Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/perbu.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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-07-07T08:52:20.000Z","updated_at":"2025-07-07T09:19:46.000Z","dependencies_parsed_at":"2025-07-07T09:46:20.076Z","dependency_job_id":"12b09570-7f07-4c0b-a1e5-1191b65a7c97","html_url":"https://github.com/perbu/gitsummarize","commit_stats":null,"previous_names":["perbu/gitsummarize"],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/perbu/gitsummarize","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/perbu%2Fgitsummarize","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/perbu%2Fgitsummarize/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/perbu%2Fgitsummarize/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/perbu%2Fgitsummarize/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/perbu","download_url":"https://codeload.github.com/perbu/gitsummarize/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/perbu%2Fgitsummarize/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35410672,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-13T02:00:06.543Z","response_time":119,"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":[],"created_at":"2025-09-26T23:26:10.126Z","updated_at":"2026-07-13T05:01:58.659Z","avatar_url":"https://github.com/perbu.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gitsummarize\n\n`gitsummarize` is a command-line tool written in Go that summarizes git commits from a specified repository. It can aggregate commits by day and generate a concise summary for each day using either the Google Gemini API or a local Ollama instance. The output is a CSV file containing daily summaries, including commit counts, lines changed, and an AI-generated summary.\n\n## Features\n\n*   **Git Commit Aggregation:** Groups commits by day.\n*   **AI-Powered Summarization:** Utilizes Google Gemini or Ollama to generate daily summaries of commit messages and diffs.\n*   **Effort Calculation:** Provides a simple \"effort\" metric based on commit count and lines changed.\n*   **CSV Output:** Generates a CSV report for easy analysis.\n*   **Filtering:** Filter commits by author and date range.\n\n## Installation\n\nTo build `gitsummarize` from source, you need Go installed (version 1.24 or higher).\n\n```bash\ngit clone https://github.com/perbu/gitsummarize.git\ncd gitsummarize\ngo build -o gitsummarize .\n```\n\nThis will create an executable named `gitsummarize` in the current directory.\n\n## Usage\n\n```bash\n./gitsummarize [flags]\n```\n\n### Flags\n\n*   `--summarize`: Enable summarization.\n*   `--model string`: The model to use for summarization (e.g., `gemini-1.5-flash`, `llama3`). If the model name starts with `gemini`, the Gemini API will be used. Otherwise, a local Ollama instance will be used.\n*   `--batched`: Use batched Ollama for summarization. This is only applicable when using Ollama.\n*   `--gemini-api-key string`: Your Google Gemini API key. Can also be set via the `GEMINI_API_KEY` environment variable.\n*   `--repo string`: Path to the git repository (default: `.` - current directory).\n*   `--start-date string`: Optional start date in `YYYY-MM-DD` format to filter commits.\n*   `--end-date string`: Optional end date in `YYYY-MM-DD` format to filter commits.\n*   `--author string`: Optional author email to filter commits.\n\n### Examples\n\n**Summarize commits in the current repository using Gemini:**\n\n```bash\n./gitsummarize --summarize --model gemini-1.5-flash --gemini-api-key YOUR_GEMINI_API_KEY\n```\n\n**Summarize commits in a specific repository using Ollama:**\n\n```bash\n./gitsummarize --summarize --repo /path/to/your/repo --model llama3\n```\n\n**Summarize commits by a specific author within a date range using batched Ollama:**\n\n```bash\n./gitsummarize --summarize --repo /path/to/your/repo --author \"john.doe@example.com\" --start-date \"2024-01-01\" --end-date \"2024-01-31\" --model llama3 --batched\n```\n\n## Output\n\nThe tool outputs a CSV report to standard output (stdout) with the following columns:\n\n*   `date`: The date of the daily summary (`YYYY-MM-DD`).\n*   `effort in terms of days of work`: A calculated effort metric.\n*   `no of commits`: Number of commits on that day.\n*   `commit SHAs`: Space-separated list of commit SHAs.\n*   `lines added`: Total lines added on that day.\n*   `lines deleted`: Total lines deleted on that day.\n*   `summary`: The AI-generated summary of the day's commits.\n\nYou can redirect the output to a file:\n\n```bash\n./gitsummarize --summarize --gemini-api-key YOUR_GEMINI_API_KEY \u003e daily_report.csv\n```\n\n## Configuration\n\n### Gemini API Key\n\nYou can provide your Gemini API key either via the `--gemini-api-key` flag or by setting the `GEMINI_API_KEY` environment variable.\n\n### Ollama\n\nIf you choose to use Ollama, ensure you have Ollama installed and running, and that the specified model is available.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fperbu%2Fgitsummarize","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fperbu%2Fgitsummarize","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fperbu%2Fgitsummarize/lists"}