A Shell provides you with an interface to the Unix system. It gathers input from you and executes programs based on that input. When a program finishes executing, it displays that program's output.
Shell is an environment in which we can run our commands, programs, and shell scripts. There are different flavors of a shell, just as there are different flavors of operating systems. Each flavor of shell has its own set of recognized commands and functions.
And minishell is my interpretation of the legendary shell.
- Search and launch the right executable (based on the PATH variable, using a relative or an absolute path)
- Environment variables ($ followed by a sequence of characters) expand to their values
’(single quotes - prevent from interpreting meta-characters in quoted sequence)"(double quotes - prevent from interpreting meta-characters in quoted sequence except for $)|connect cmds or groups with pipes; output of a cmd is connected to the input of the next cmd via a pipe
< fileRedirecting Input<<limiterHere Documents> fileRedirecting Output>> fileAppending Redirected Output
echowith option -ncdwith relative/absolute pathpwdwithout optionsenvwithout optionsunset [env]without optionsexit [exit_status]without options
-
Cloning this repository
git clone --recurse-submodules https://github.com/Kllaster/minishell.git -
cdinto the root directorycd minishell -
Creating a program from source code
make
git clone --recurse-submodules https://github.com/Kllaster/minishell.git\
&& cd minishell\
&& make
./minishell
