Skip to content

2radu3/rust-cli-tools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

9 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ¦€ rust-cli-tools

A hands-on educational project reimplementing classic Unix command-line tools in Rust β€” to learn:

  • File I/O & system calls (std::fs, std::io)
  • Manual argument parsing (no external crates)
  • Robust error handling with Result and ?
  • Process control, exit codes, and CLI design

πŸ›  Implemented Commands βœ…

Command Features
echo -n, --no-newline
cat concatenate files, read from stdin (-), basic error handling
stat display file type, size, permissions, owners, modified date, etc...
pwd print working directory
mkdir create directories (mkdir dir1 dir2)
rmdir remove empty directories
mv move/rename files and directories
ln create hard links and symbolic links
head print first 10 lines of a file
date print current date/time
env print environment variables

πŸ“Œ All tools exit with proper status codes and print helpful errors (no panic! on user mistakes).


πŸš€ Quick Start

Build

git clone https://github.com/2radu3/rust-cli-tools.git
cd rust-cli-tools
cargo build

About

A minimal reimplementation of Unix CLI tools in pure Rust

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages