Skip to content

A custom shell is a user-created program that acts as a command-line interpreter (CLI), providing an interface to the operating system. It accepts text commands from a user or script, interprets them, executes the corresponding programs or built-in functions, and manages input/output, all within a read-eval-print loop (REPL).

Notifications You must be signed in to change notification settings

omkarrr2533/Custom-Shell-Command-Line-Interpreter-

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Custom Shell Project

A fully functional Unix-like shell implementation in C.

Features

  • Execute system commands
  • Built-in commands (cd, exit, help, history)
  • I/O redirection (>, <, >>)
  • Piping (|)
  • Background processes (&)
  • Signal handling (Ctrl+C, Ctrl+Z)
  • Command history

Project Structure

custom_shell/
├── src/           # Source files
├── include/       # Header files
├── obj/           # Object files
├── bin/           # Binary executable
├── tests/         # Test files
├── docs/          # Documentation
└── Makefile       # Build configuration

Building

make

Running

make run
# or
./bin/myshell

Cleaning

make clean

Usage

Once running, you can use standard shell commands:

  • ls, pwd, echo, etc.
  • cd [directory] - Change directory
  • exit - Exit the shell
  • help - Show help information
  • history - Show command history

Examples

myshell> ls -la
myshell> cat file.txt | grep "search"
myshell> echo "Hello" > output.txt
myshell> gcc program.c -o program &

About

A custom shell is a user-created program that acts as a command-line interpreter (CLI), providing an interface to the operating system. It accepts text commands from a user or script, interprets them, executes the corresponding programs or built-in functions, and manages input/output, all within a read-eval-print loop (REPL).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published