Skip to content

vgomes-p/minishell-42

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

103 Commits
 
 
 
 
 
 
 
 

Repository files navigation

cover Minishell-42 is a minimalist Unix-style shell implemented in C, created to mimic basic behaviors of shells such as bash. It was developed as part of the 42 curriculum and focuses on understanding core system programming concepts like process control, file descriptors, built-ins, redirections, pipes, environment variables, and signal handling.

print_minishell

📥 Requirements

Before building and running the project:

  • A Unix-like system (Linux, macOS, or Windows with WSL)
  • A C compiler (cc, gcc, or similar)
  • make installed
  • GNU Readline library for command line input handling (see the end of readme)

1 - Cloning the Repository

git clone git@github.com:vgomes-p/minishell-42.git

2 - Navigate into the project directory

cd minishell-42/project

3 - Run the command make

make

This will generate the minishell executable.

4 - Running the Shell

./minishell

Makefile Shortcuts

Rebuild in debug mode

make debug

Recreate the binary

make re

Create dependencies read file

To see the program dependencies, run:

make depend

and then

cat dependencies.mk

or open the <dependencies.mk> on your favorite file reader.

Clean build artifacts

make clean

or

make fclean

Installing Readline (If Needed)

1 - Run the following commands

On Linux / WSL

sudo apt-get update
sudo apt install libreadline-dev

On macOS

brew install readline

Machine may require linking include and lib paths depending on your environment.

About

Work in Progress on README

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages