https://github.com/lobbyra/minishell
Light bash reproduction for a 42 school project
https://github.com/lobbyra/minishell
42school bash c group
Last synced: 2 months ago
JSON representation
Light bash reproduction for a 42 school project
- Host: GitHub
- URL: https://github.com/lobbyra/minishell
- Owner: Lobbyra
- License: mit
- Created: 2020-06-11T13:28:47.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2021-09-27T08:38:39.000Z (over 4 years ago)
- Last Synced: 2025-10-26T01:46:11.848Z (8 months ago)
- Topics: 42school, bash, c, group
- Language: C
- Homepage:
- Size: 1.55 MB
- Stars: 1
- Watchers: 0
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Minishell - [@42Born2code](https://www.youtube.com/watch?time_continue=88&v=eawhnhTO2oY&feature=emb_logo)

---
## Introduction
Minishell is a group project at [42](https://www.42.fr/). The goal of this project is to create a simple shell that behave like bash.
This project was carried out by [__Jecaudal__](https://github.com/lobbyra) and [__Jereligi__](https://github.com/Jean-xavierr)
## Subject
We based on bash behavior.
__*Rules of project*__
__implement the following builtins:__
- `echo` and the `-n` option
- `cd` only with an absolute or relative path
- `pwd` without any options
- `export` without any options
- `unset` without any options
- `env` without any options or arguments
- `exit` without any options
__The function to be implemented in the project__
- Display a prompt while waiting for a new order.
- Find and launch the correct executable (based on a PATH environment variable
or using an absolute path).
- `;` in the command line must separate the commands.
- `’`and `"` must work as in bash, except multiline.
- The `<`,`>` and `>>` redirects must work as in bash, except for
aggregations of fd.
- Pipes redirections `|`.
- The environment variables ($ followed by characters) must work.
- `$?` variable.
- `ctrl-C`, `ctrl-D` and `ctrl- \` signals should have the same behavior.
This project is coded in C with our proper norm at 42.
__Project duration__ : 4 weeks
## Installation 🖥
Run the Makefile with the `make` command to compile all the files
Then run the executable `./minishell`
```bash
minishell[/Users/user42/Desktop/minishell]$>
```
## Tips project
> ⚠️ **Warning**: Don't copy/paste code you don't understand: it's bad for you, and for the school. I have put my login in a lot of files to encourage you doing your own version. Have fun !
- Know and test your shell very well !
- Organize and structure your project
## Project documentation 📚
[bash reference manual](https://www.gnu.org/software/bash/manual/bash.pdf)
## Contributing, Questions or suggestions ?
__42Slack :__ __*@jecaudal*__ or __*@jereligi*__
__42Intra :__ [@jecaudal](https://profile.intra.42.fr/users/jecaudal) or [@jereligi](https://profile.intra.42.fr/users/jereligi)
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
Thanks for reading this read me, advice or corrections are welcome