Skip to content

runlevel5/htop-rs

Repository files navigation

htop-rs

htop-rs

A Rust port of htop, the beloved interactive process viewer.

What is this?

htop-rs aims to be a 1:1 faithful recreation of htop's user interface and functionality, implemented entirely in Rust. If you're familiar with htop, you should feel right at home.

Why?

This project exists to explore Rust and experiment with new patterns and architectures—free from the technical debt that accumulates in any long-lived C codebase. It's a learning exercise, a playground for ideas, and hopefully a useful tool.

Goals:

  • Match htop's UI pixel-for-pixel (or character-for-character)
  • Maintain feature parity with C htop
  • Explore Rust idioms for systems programming
  • Experiment with architectural improvements

Non-goals:

  • Adding features that diverge from htop's design philosophy

Building

cargo build --release

Dependencies

  • Rust 1.93+

No external libraries required - htop-rs uses a pure Rust terminal implementation.

Running

cargo run --release

Or after building:

./target/release/htop-rs

Current Status

Work in progress. Many features work, but not everything is implemented yet.

Working:

  • Process list with sorting and filtering
  • Tree view
  • CPU, Memory, Swap meters
  • Multiple meter display modes (Bar, Text, LED)
  • Setup screen (F2) with meter configuration
  • Color themes
  • Keyboard navigation
  • Process actions (kill, nice, etc.)

Not yet implemented:

  • Some column types show "TODO"
  • Graph meter mode
  • Some platform-specific features

Known Issues

  • Kitty Keyboard Protocol: htop-rs has known compatibility issues with terminal emulators that use the Kitty keyboard protocol. If you experience keyboard input problems, it is advised to disable the Kitty keyboard protocol in your terminal settings.

Platform Support

Platform Status
Linux Primary target, most complete
macOS Supported, some features limited
FreeBSD Planned (see TODO.md)

Contributing

Contributions are greatly welcome! Whether it's:

  • Implementing missing features
  • Fixing bugs
  • Improving documentation
  • Adding tests
  • Platform-specific improvements

Feel free to open issues or submit pull requests.

Vision

See TODO.md for unimplemented features, planned enhancements and architectural ideas.

License

GPL-2.0-or-later (same as htop)

Acknowledgments

  • The htop project and its maintainers
  • btop++ for inspiration on conservative threading design
  • Everyone who has contributed to htop over the years