lazyenv

command module
v0.9.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 13, 2026 License: MIT Imports: 8 Imported by: 0

README

lazyenv

Go Report Card codecov GoDoc License Go Version GitHub tag GitHub Downloads Last commit

TUI for managing .env files — written in Go with Bubble Tea.

Browse, compare, edit and validate environment variables from your terminal.

Documentation | Releases

lazyenv demo

Features

  • Two-panel layout with file list and variables, inline editing
  • File management: create, duplicate, rename, delete, and generate templates — all without leaving the TUI
  • Side-by-side diff between two files with bidirectional copy
  • Completeness matrix showing which variables exist across files
  • Change tracking: new, modified, deleted, duplicate, empty, placeholder
  • Secret masking, gitignore check, automatic backup — all configurable
  • Clipboard support (OSC 52), search, sort, prefix-based grouping, and on-disk reorder
  • Round-trip fidelity: saves preserve comments, blank lines, quoting
  • TOML configuration: layout, colors, file patterns, behaviors
  • Mouse support: click to select, scroll wheel to navigate (disable with --no-mouse)
  • 56 built-in color themes with interactive preview (--themes)

Install

Homebrew (macOS & Linux):

brew install lazynop/tap/lazyenv

AUR (Arch Linux):

yay -S lazyenv-bin

Scoop (Windows):

scoop bucket add lazynop https://github.com/lazynop/scoop-bucket
scoop install lazyenv

Or download a binary from Releases, or install from source (requires Go 1.26+):

go install github.com/lazynop/lazyenv@latest

Quick start

lazyenv                  # scan current directory for .env files
lazyenv path/to/dir      # scan a specific directory
lazyenv -r               # scan recursively into subdirectories

See the full documentation for usage & flags, configuration, and keybindings.

License

MIT

Documentation

Overview

Package main is the lazyenv entry point: it parses CLI flags via Kong, loads configuration, applies overrides, and starts the Bubble Tea program.

Directories

Path Synopsis
internal
config
Package config defines the application configuration types, loads them from TOML, validates them, and resolves theme + color precedence.
Package config defines the application configuration types, loads them from TOML, validates them, and resolves theme + color precedence.
config/themes
Package themes catalogs the built-in color palettes and exposes a case-insensitive name lookup.
Package themes catalogs the built-in color palettes and exposes a case-insensitive name lookup.
model
Package model holds the domain types for lazyenv: EnvFile, EnvVar, RawLine, and DiffEntry.
Package model holds the domain types for lazyenv: EnvFile, EnvVar, RawLine, and DiffEntry.
parser
Package parser reads and writes .env files with round-trip fidelity.
Package parser reads and writes .env files with round-trip fidelity.
tui
Package tui implements the lazyenv terminal UI built on Bubble Tea v2: the Model-Update-View loop, the keymap, and the sub-models for the file list, var list, diff view, matrix view, and inline editor.
Package tui implements the lazyenv terminal UI built on Bubble Tea v2: the Model-Update-View loop, the keymap, and the sub-models for the file list, var list, diff view, matrix view, and inline editor.
util
Package util contains cross-cutting helpers: secret-key heuristics and placeholder-value detection.
Package util contains cross-cutting helpers: secret-key heuristics and placeholder-value detection.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL