Skip to content

welf/codecrafters-shell-rust

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

progress-banner

This is a repo for Rust solutions to the "Build Your Own Shell" Challenge.

Challenge Status

The entry point for this shell implementation is in src/main.rs. This simple shell implementation includes:

  • REPL implementation (run ./your_shell.sh to start the REPL)
  • handling unknown commands
  • echo, exit, and type built-in commands
  • printing the full path to external executables if they are found in the PATH (run type mkdir in the REPL as an example)
  • running external executables with arguments (run ls -l -s in the REPL as an example)
  • implementing the pwd built-in command
  • implementing the cd built-in command

Running the Shell

  1. Ensure you have cargo (1.70) installed locally
  2. Run ./your_shell.sh to run your program, which is implemented in src/main.rs. This command compiles your Rust project, so it might be slow the first time you run it. Subsequent runs will be fast.
  3. Execute commands in the REPL that appears. You can run any command that you would normally run in a shell.

About

CodeCrafters challenge: Build your own Shell

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published