Skip to content

thirstymelon/rat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

2 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation


rat - Rust-based πŸ¦€

A minimal cat clone written in Rust.

rat streams file contents to standard output using buffered I/O. It's designed to teach low-level file handling and Unix tool internals.


✨ Features

  • Buffered file reading
  • Streams raw bytes to stdout
  • Memory efficient (no full file loading)
  • Unix-style error handling
  • Safe, idiomatic Rust

πŸš€ Usage

Development:

cargo run notes.txt

Install binary:

cargo build --release
sudo cp target/release/rat /usr/local/bin/
rat file.txt

πŸ’‘ Examples

rat Cargo.toml
rat src/main.rs  
rat /etc/hosts

⚠️ Limitations

  • Single file only
  • No stdin support
  • No line numbering
  • Fixed buffer size

Future versions will add full cat compatibility.


🎯 Learning Goals

  • Low-level file I/O
  • Buffered reading/writing
  • Error handling
  • Data streaming

πŸ“œ License

MIT License


About

Minimal cat clone in Rust (low-level file streaming)

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages