Skip to content

agmankaruse/posix-shell

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

POSIX-Based Shell

A small Unix-style shell written in C for Linux. The shell implements command parsing, process creation, foreground/background execution, signal handling, built-in commands, and circular-buffer command history.

Features

  • Reads user input using read()
  • Executes programs using fork(), execvp(), and waitpid()
  • Supports foreground process execution
  • Supports background execution using &
  • Handles SIGINT so Ctrl-C does not kill the shell itself
  • Reaps completed background processes with waitpid(..., WNOHANG)
  • Supports built-in commands:
    • cd
    • exit
    • history
  • Implements circular-buffer command history
  • Supports command recall:
    • r recalls the most recent command
    • r x recalls the most recent command starting with x

Build

make

Run

./build/minishell

Test

make test

Clean

make clean

Tech Stack

C, Linux, POSIX, process management, signals, Make, Git

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors