Coder Social home page Coder Social logo

minishell's Introduction

minishell

Keyboard handling

Mandatory
  1. Normal input such as alphabets and numbers
  2. Arrow up and arrow down for browsing history
  3. Ctrl-D, Ctrl-C, Ctrl-\ send signals as in bash
Bonus
  1. Backspace and delete work as in bash
  2. Arrow left and arrow right work as in bash (to move the cursor)
  3. Ctrl-L works as in bash
  4. Home and end to move the cursor to the beginning or the back of the line respectively

Parsing

Mandatory
  1. Quotes (') and double quotes (") work as in bash except for multiline commands
  2. Pipe ('|') works as in bash
  3. Redirections ('<', '>', '<<'. '>>') work as in bash
  4. Dollar sign ('$') looks for the corresponding environment variable or "$?"
Bonus
  1. Backslash ('\') works as in bash except for multiline commands
  2. Semicolon (';') works as in bash
  3. Wildcard : Asterisk ('*') and question mark ('?') work as in bash (not only in current working direcotry)
  4. Tilde ('~') works as in bash except when $HOME is not set (A forbidden function is necessary to simulate this situation).

Builtins

Mandatory

  1. 'cd' with both relative and absolute path work as in bash
  2. 'echo' and with option -n work as in bash
  3. 'env' works as in bash except with options or arguments
  4. 'exit' works as in bash except with options
  5. 'export' works as in bash except with options
  6. 'pwd' works as in bash except with options
  7. 'unset' works as in bash except with options

Bonus

  1. 'cd ~' works as in bash except when $HOME is not set (A forbidden function is necessary to simulate this situation).
  2. 'cd --' works as in bash
  3. 'cd -' works as in bash

Other features

Change text color and change prompt color

supported colors :

BLACK, WHITE, RED, GREEN, YELLOW, PURPLE, BLUE, CYAN

usage :

To change text color, simply type one of the "supported colors" in capital letters.

intro1

To change prompt color, type P_"supported color" in capital letters.

intro2

minishell's People

Contributors

leofu9487 avatar xinyunpepe avatar

Stargazers

Tanguy Chappuis avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.