Welcome to the Holberton School Simple Shell project! This simple shell, developed by Nour Mohamed Derbeli, Eya Kadri, and Ahmed Hamri, is designed to handle command lines with arguments, manage the PATH, and include built-in functionalities.
This simple shell is a project developed for Holberton School. It includes the following features:
- Handling command lines with arguments
- Managing the PATH
- Not calling fork if the command doesn't exist
- Implementing the
exit
built-in to exit the shell - Implementing the
env
built-in to print the current environment
The project consists of the following files:
AUTHORS
README.md
(You are here!)built-in.c
exec.c
free_array.c
getenv.c
handle_path.c
main.c
man_1_simple_shell
my_strdup.c
The shell efficiently handles command lines with arguments, ensuring a smooth execution of commands.
The PATH is managed to locate executable files and execute commands.
The fork is not called if the command doesn't exist, optimizing the execution process.
The shell includes the exit
built-in, allowing users to exit the shell easily.
Usage:
$ exit
The env
built-in is implemented to print the current environment.
To use the simple shell, follow these steps:
-
Clone the repository:
git clone https://github.com/MohamedNourDerbeli/holbertonschool-simple_shell.git
-
Compile the shell:
gcc -Wall -Werror -Wextra -pedantic *.c -o hsh
-
Run the shell:
./hsh
-
Enjoy using the simple shell!
No known bugs.
We have written an article in which we deepen the internal processes within the shell by typing the command "ls -l *.c". We talk about fundamental elements such as the PATH, and conclude with the permission structure with some examples.