# ftdv

> Terminal-based diff viewer for Git with interactive file tree navigation and configurable external diff tool support.

Stars: 72 · Language: Rust · License: Apache-2.0 · Categories: Git · Status: archived

- Repository: https://github.com/wtnqk/ftdv
- Page: https://www.trmn.sh/tools/ftdv

## Install

- Cargo: `cargo install ftdv`

## Overview

ftdv is a terminal-based Git diff viewer that combines interactive file tree navigation with flexible external diff tool integration. Built with Rust and ratatui, it provides a file-by-file diff interface where users can navigate through changed files in a tree structure and view diffs using configurable external tools like delta, bat, ydiff, or difftastic.

The tool supports multiple Git operations including working directory changes, staged changes, branch comparisons, and direct file/directory comparisons. It features vim-style keyboard navigation, directory folding, search functionality with real-time filtering, and checkbox tracking for marking reviewed files. The diff content is generated fresh for each selected file, with automatic ANSI color detection and rendering.

ftdv uses a YAML configuration system that allows users to configure different diff tools with template variables for width control and color settings. It distinguishes between pager-based tools (that accept stdin) and external diff commands (invoked by Git with file paths). The tool maintains persistent state for checked files and provides customizable themes for both dark and light terminal environments.

### Installation

```bash
# via Cargo
cargo install ftdv
```

![ftdv interface showing file tree and diff view](https://media.trmn.sh/cached/9cb6298ced8348753edaa434492dd5c317d770a5f18b738661acdd2709987c1e.png)

## Alternatives

- [gitnr](https://www.trmn.sh/tools/gitnr.md): Cross-platform CLI tool for creating .gitignore files from GitHub and TopTal template collections (Rust, 239 stars)
- [lazyjj](https://www.trmn.sh/tools/lazyjj.md): Terminal UI for Jujutsu version control system, providing interactive log browsing, file management, and bookmark operations (Rust, 1.2k stars)
- [serie](https://www.trmn.sh/tools/serie.md): Terminal UI for git commit graphs using image protocols to render rich visualizations in supported terminals (Rust, 2.2k stars)
- [gitu](https://www.trmn.sh/tools/gitu.md): Terminal user interface for Git inspired by Magit, providing visual staging, branching, and repository management (Rust, 2.9k stars)
- [git absorb](https://www.trmn.sh/tools/git-absorb.md): Git subcommand that automatically creates fixup! commits from staged changes by finding the commit each hunk belongs to, with optional autosquash rebase. (Rust, 5.8k stars)

---

Canonical: https://www.trmn.sh/tools/ftdv
