Skip to main content

Terminal source tree viewer with split-pane preview and search

Project description

LazyViewer

A TUI source code viewer I vibe coded to browse full source code with git diff previews inline with easy keyboard navigation of both the source code and the file tree.

As I am coding with LLMs, they create a lot of code that I wanted to browse fast, and I haven't found a great viewer for it where I can see the changes like in Cursor/VSCode GUI, but still fit well with the TUIs. The best I found were LazyGit (awesome tool) and nvim tree view with preview, but with LazyGit I couldn't browse all the files, just the changes, and nvim's tree browser with preview was quite slow and is not optimized for viewing these changes either.

I created a simple tool, LazyViewer that is just between these 3 tools and optimized for my most common workflow for understanding the code base that LLMs create.

It has syntax highlighting, shows the function headers, is able to browse multiple project trees, respects .gitignore and hidden files (but can be turned off), git overlay is on by default, but it can be turned off, and it's quite interactive (ripgrep for a syntax with a mouse click for example).

There are lots of ways I'm tempted to improve it (inline editor support?), but at the same time I'm trying to keep it minimal and focus on the smooth interaction of the features that isn't available using other tools that treat them as separate features of a more complex program.

The code base is really ugly, far from how I'd like it to be, but it's partly because I started working on it with codex before this program existed :)

I'm having fun using/developing it though, hopefully it will be fun/useful for others as well.

Tip: add alias lv='lazyviewer' to your shell config.

Install

The easiest way:

pipx install lazyviewer

Or with pip:

pip install lazyviewer

/ content search uses ripgrep (rg). Install it with your package manager:

  • macOS (Homebrew): brew install ripgrep
  • Ubuntu/Debian: sudo apt install ripgrep
  • Fedora: sudo dnf install ripgrep
  • Arch: sudo pacman -S ripgrep
  • Windows (winget): winget install BurntSushi.ripgrep

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lazyviewer-0.1.0.tar.gz (126.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

lazyviewer-0.1.0-py3-none-any.whl (161.8 kB view details)

Uploaded Python 3

File details

Details for the file lazyviewer-0.1.0.tar.gz.

File metadata

  • Download URL: lazyviewer-0.1.0.tar.gz
  • Upload date:
  • Size: 126.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for lazyviewer-0.1.0.tar.gz
Algorithm Hash digest
SHA256 c0765d41f5154a8e65a0dd3ce9dcf2cfd712bce96cf426c01d44067d16f29ba3
MD5 64907ab6335e361b93978aafb5d211e3
BLAKE2b-256 22e26ed81622cb77481002adefd507af0a72ee0d236506469709ac88bf89c917

See more details on using hashes here.

Provenance

The following attestation bundles were made for lazyviewer-0.1.0.tar.gz:

Publisher: publish-pypi.yml on adamritter/lazyviewer

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file lazyviewer-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: lazyviewer-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 161.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for lazyviewer-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 02d92452e5d22306d072955f3739947ca1a7274b354861bc21a3995dc497dd9a
MD5 6a8391d37ddfc8c33fba50ea267cc2a4
BLAKE2b-256 76f0c96abc1e5e20320150af3c4ddd1d0b868c3225e3663d99ab4a8cde38f10b

See more details on using hashes here.

Provenance

The following attestation bundles were made for lazyviewer-0.1.0-py3-none-any.whl:

Publisher: publish-pypi.yml on adamritter/lazyviewer

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page