Skip to content

vdedios/minishell

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Minishell

MIT License

Minishell is a simple and lightweight shell, coded from scratch, which emulates several functionalities from bash.

demo

Project specifications

This shell covers the following functionalities:

  • Show a prompt when waiting for a new command
  • Search and launch the right executable (based on the PATH variable or by using relative or absolute path) like in bash
  • Implement some builtins like in bash:
    • echo with option ’-n’
    • cd with only a relative or absolute path
    • pwd without any options
    • export without any options
    • unset without any options
    • env without any options and any arguments
    • exit without any options
  • ; in the command separates commands like in bash
  • ’ and " like in bash except for multiline commands
  • Redirections < > β€œ>>” like in bash except for file descriptor aggregation
  • Pipes | like in bash except for multiline commands
  • Environment variables like in bash
  • $? like in bash
  • ctrl-C, ctrl-D and ctrl-\ have same result as in bash

Usage

Clone the project

    git clone https://github.com/vdedios/minishell

Go to the project directory

    cd project-directory

Compile source code

    make

Run the shell

    ./minishell

Tests

This project has been exhaustively tested with @cacharle minishell tester achieving a 100% coverage. We highly recommend to use it:

    pip3 install minishell-test
    cd <MINISHELL>
    minishell_test

Contributors


@vdedios

@migferna42

Support

If you find any issue we suggest that you open a PR with the fix πŸ™‚

About

🐚 As beautiful as shell

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published