Skip to content
Edith

Docs

Developer & Data

Code Stats

Code Stats keeps a read-only copy of your GitHub repositories on a folder you choose, counts your commits and lines, and turns them into streaks, languages and a daily heatmap. Nothing is changed on GitHub. Read the Code Stats overview for screenshots and use cases.

Code Stats for the last 90 days with 266 commits and 12.6K lines authored across 6 repositories, a daily contribution heatmap and weekly output chart
Code Stats for the last 90 days with 266 commits and 12.6K lines authored across 6 repositories, a daily contribution heatmap and weekly output chart

Install Code Stats

  1. Open Library in Edith's sidebar.
  2. Search for Code Stats in Search tools, or open the Developer & Data category.
  3. Press Install. Code Stats is added to your sidebar.

From the terminal, ed extensions install codeStats does the same. See Extensions for turning extensions off, updating and removing them.

Where to find Code Stats

  • Sidebar. Click Code Stats in the sidebar to open its page, or press ⌘K and type its name.
  • Home. Open Home, press Edit Home, then Add widgets to place its widgets.

Get started with Code Stats

  1. Choose a storage folder. Pick where repository copies are kept; an external drive works.
  2. Confirm it is you. Sign in with the GitHub CLI and confirm which emails count as your commits.
  3. Run the first sync. Edith copies and reads your repositories in the background; the first run takes the longest.
  4. Explore your stats. Filter by range, repository or language, and share cards as images.

What Code Stats does

  • See how much code you write. Commits, lines, streaks and languages across your repositories.

From the terminal

Everything above works in the app. The ed command line is optional, for scripts and coding agents. Code Stats's commands are in ed code-stats, and each one is also a tool in Edith's MCP server.

Terminal
ed code-stats statused code-stats run --waited code-stats report --range 30ded code-stats audit

Permissions and requirements

  • macOS 14 or later on Apple silicon
  • The GitHub CLI (gh), signed in
  • Free disk space for bare copies of your repositories
  • No macOS privacy permissions
  • Access to the storage folder you pick, including folders on external drives
  • A GitHub CLI sign-in that can read your repositories

See Permissions for how Edith asks for each one.

Questions

Does Code Stats change anything on GitHub?

No. It lists your repositories through the GitHub API, then clones and fetches them as bare copies. It never pushes, opens issues or edits settings on GitHub.

Which repositories are counted?

Repositories you own, collaborate on, or can see as an organization member. Archived repositories are included and forks are left out by default, and both settings can be changed. You can also exclude whole GitHub CLI accounts.

Why do my numbers differ from GitHub's contribution graph?

They measure different things. GitHub counts contributions, mostly commits on default branches plus issues and pull requests. Code Stats counts your commits on every branch and tag, skips merge commits, and counts lines with generated files removed. ed code-stats audit lists what was included and excluded.

Can an agent pull my code stats over MCP?

Yes. The ed code-stats commands are tools in Edith's MCP server, such as edith_code_stats_report for a 30-day, 90-day, yearly or all-time report, edith_code_stats_status for the last refresh and edith_code_stats_run to start one.

How much disk space does the mirror use?

About as much as the .git folders of the repositories it copies, because each copy is a bare clone with history but no checked-out files. Large repositories with long histories take the most.

Is Code Stats included in Edith's one-time price?

Yes. Code Stats comes with every Edith license. There is no extra charge for private repositories or for the number of repositories mirrored.