# astral-sh/ruff SLOC report

> astral-sh/ruff: 644,215 code lines at commit 7a8f63f0d71a, counted with tokei-14.0.0 on 2026-10-22. Saved result 1b41ab2f8de45b98160b2369d70bfddfc7d01ea332b72c61dafacd6c43772d28.

astral-sh/ruff has 644,215 source lines of code out of 1,263,129 total lines across 3,876 files, counted from the main ref at commit 7a8f63f0d71a by the OctoCounts tokei engine on 2026-10-22. The report is cached by commit, tokei version, and analysis options, so recounting the same revision returns exactly these numbers.

OctoCounts produced this report by resolving astral-sh/ruff to commit 7a8f63f0d71a, downloading the repository source archive, and counting every source file with tokei, the open-source line counter written in Rust. The table below breaks the count down by programming language into files, total lines, code lines, comment lines, and blank lines, so the figures can be compared across languages and projects. Results are cached by commit, tokei version, and analysis options, so counting the same revision again reproduces exactly these numbers.

## Repository size insights

This is a large codebase by counted code lines. Code represents 51.0% of all lines, comments represent 37.4%, and the repository averages 166 code lines per file. Rust accounts for 91.6% of counted code.

| Language | Files | Lines | Code | Comments | Blanks |
| --- | ---: | ---: | ---: | ---: | ---: |
| Rust | 1,907 | 688,821 | 590,185 | 30,974 | 67,662 |
| Python | 1,000 | 24,510 | 18,829 | 2,126 | 3,555 |
| JSON | 22 | 16,879 | 16,871 | 0 | 8 |
| TSX | 31 | 6,547 | 5,730 | 174 | 643 |
| TOML | 132 | 6,235 | 5,272 | 249 | 714 |
| YAML | 31 | 6,072 | 5,115 | 495 | 462 |
| SVG | 17 | 1,131 | 1,024 | 71 | 36 |
| TypeScript | 18 | 756 | 561 | 104 | 91 |
| Shell | 14 | 459 | 255 | 138 | 66 |
| CSS | 2 | 252 | 222 | 0 | 30 |
| HTML | 2 | 81 | 81 | 0 | 0 |
| Jinja2 | 1 | 61 | 44 | 0 | 17 |
| Dockerfile | 1 | 38 | 26 | 7 | 5 |
| Markdown | 656 | 282,747 | 0 | 209,731 | 73,016 |
| Plain Text | 42 | 228,540 | 0 | 228,523 | 17 |

Top language (Rust 91.6%). Generated at 2026-10-22T05:09:25.995056470Z. Canonical report: https://octocounts.com/github/astral-sh/ruff/commit/7a8f63f0d71a1d381f99652a5fee3b043b32e8e6?reportId=1b41ab2f8de45b98160b2369d70bfddfc7d01ea332b72c61dafacd6c43772d28&analysis=%7B%22profile%22%3A%22default%22%2C%22ignoredDirs%22%3A%5B%5D%2C%22includeDocs%22%3Afalse%2C%22includeTests%22%3Afalse%2C%22ignoredLanguages%22%3A%5B%5D%2C%22includeGenerated%22%3Afalse%7D

## Reproduce this report

[Reproduce this exact report and configuration](https://octocounts.com/github/astral-sh/ruff/commit/7a8f63f0d71a1d381f99652a5fee3b043b32e8e6?reportId=1b41ab2f8de45b98160b2369d70bfddfc7d01ea332b72c61dafacd6c43772d28&analysis=%7B%22profile%22%3A%22default%22%2C%22ignoredDirs%22%3A%5B%5D%2C%22includeDocs%22%3Afalse%2C%22includeTests%22%3Afalse%2C%22ignoredLanguages%22%3A%5B%5D%2C%22includeGenerated%22%3Afalse%7D).

## Report FAQ

### How many lines of code does astral-sh/ruff have?

astral-sh/ruff has 1,263,129 total lines, including 644,215 code lines, 472,592 comment lines, and 146,322 blank lines.

### How was the astral-sh/ruff line count measured?

OctoCounts resolved the public GitHub repository to commit 7a8f63f0d71a, downloaded the source archive, counted it with tokei, and cached the report by commit, tokei version, and analysis options.

### What commit was counted for astral-sh/ruff?

This OctoCounts report was generated from main at commit 7a8f63f0d71a on 2026-10-22T05:09:25.995056470Z.

## Similar repository reports

- [tikv/tikv](https://octocounts.com/github/tikv/tikv) — Rust, 638,022 code lines
- [NVIDIA/OpenShell](https://octocounts.com/github/NVIDIA/OpenShell) — Rust, 661,288 code lines
- [KonghaYao/peri](https://octocounts.com/github/KonghaYao/peri) — Rust, 620,866 code lines
- [rimio-ai/rimz](https://octocounts.com/github/rimio-ai/rimz) — Rust, 669,957 code lines
- [apache/datafusion](https://octocounts.com/github/apache/datafusion) — Rust, 677,725 code lines
- [zerx-lab/FluxDown](https://octocounts.com/github/zerx-lab/FluxDown) — Rust, 605,449 code lines

## Related OctoCounts pages

- [Recently analyzed repositories](https://octocounts.com/recent)
- [Popular SLOC reports](https://octocounts.com/popular)
- [Trending GitHub repositories](https://octocounts.com/trending)
- [Hall of Monoliths](https://octocounts.com/hall-of-monoliths)
- [Rust vs Go](https://octocounts.com/compare/rust-vs-go)
- [Electron vs Tauri](https://octocounts.com/compare/electron-vs-tauri)
- [Deno vs Node.js](https://octocounts.com/compare/deno-vs-node)
- [GitHub SLOC counter guide](https://octocounts.com/docs/github-sloc-counter)
- [Counting methodology](https://octocounts.com/docs/methodology)
- [SLOC and code metrics glossary](https://octocounts.com/docs/glossary)
- [Original research: how filtering changes SLOC counts](https://octocounts.com/research)
- [OctoCounts API docs](https://octocounts.com/docs/api)
