Skip to content

bdietrick/Rust-Custom-Shell

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Custom Rust Shell

This project is a simple custom shell written in Rust. It provides basic command-line functionality, including:

  • Running system commands (e.g., ls, cat, etc.)
  • Piping commands using |
  • Changing directories with cd
  • Viewing and modifying the shell's PATH variable with showpath and addpath
  • Exiting the shell with exit

Features

  • Cross-platform: Handles path separators for both Windows and Unix-like systems.
  • Custom PATH management: Use showpath to display the current PATH, and addpath <path> to append a new directory.
  • Basic piping: Supports simple command piping (e.g., ls | grep txt).
  • Directory navigation: Use cd <dir> to change the current working directory.

Usage

Run the shell with:

cargo run --bin my_shell

Example commands inside the shell:

my shell > showpath
my shell > addpath C:/My/Custom/Path
my shell > cd C:/Users/YourName
my shell > ls -l | grep .rs
my shell > exit

Notes

  • The shell is for educational purposes and demonstrates basic process and environment management in Rust.
  • Some advanced shell features (like background jobs, advanced piping, or scripting) are not implemented.

Example commands inside the shell:

my shell > showpath
my shell > addpath C:/My/Custom/Path
my shell > cd C:/Users/YourName
my shell > ls -l | grep .rs
my shell > exit

Notes

  • The shell is for educational purposes and demonstrates basic process and environment management in Rust.
  • Some advanced shell features (like background jobs, advanced piping, or scripting) are not implemented.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages