simple_shell's Introduction
**************************************************** Abir Abbas 0955448 CIS3110 - Assignment 1 2018-01-27 [email protected] **************************************************** Note : Bonus of adding CD was included in my shell! ************ Compilation ************ make - compiles everything make clean - cleans everything *********************** Running the program(s) *********************** ./msh - runs the program ***************** My command ***************** hash (parameters) Description : Takes in any number of strings as parameters and assigns them a somewhat unique integer value and outputs them in order of entry Example : Input : hash tomato potato tornado Output : tomato = 2959 potato = 2979 tornado = 3741 Known limitations : - Certain strings will return the same hash as each other - Will hash strings individually unless put into quotations - symbols are not given unique values Error checking : - Will say invalid syntax if nothing is inputted - Does not hash symbols, only characters ***************** Paragraph ***************** The algorithm I used follows the method provided in the textbook where, it checks for any of the user created functions we were assignmed to do, so "add", "args", "hash" and calls those accordingly, otherwise it checks for ">", "<", "&" operators within the parameters. If the <,>,& symbols are found prepare the system accordingly, ie : > prepares stdout to a file intsead of screen, < prepares stdin from a file, & prepares a signal interrupt to exit when the background process is done, but it doesn't block for the command it leaves it running in the background and moves to next statement. otherwise if none of the specified symbols are present the program just calls execvp with the command and paramanetsr (if any) and loops till user types exit.
simple_shell's People
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.