Scientific translation writing and translation typically consists of written words and documents

Job ID: 35209100

Budget: $10,000 – $20,000 USD

Scientific translation writing and translation typically consists of written words and documents

You need to design a simple shell that can handle three, internal commands – ‘cd’, ‘echo’ and ‘pwd’. These commands would be handled directly by the shell. Your shell should also be able to handle five external commands – ‘ls’, ‘cat’, ‘date’, ‘rm’ and ‘mkdir’. For these external commands you need to write individual programs to handle these commands. To handle these external commands, the shell should typically create a new process, using the fork() system ‘call and within each process you need to use the execl() family system call to run the individual
program. The parent program must also wait for the child program to terminate using the wait() family of system calls. For each of these commands, you need not handle all the command line options. Two options per command is sufficient. You need to document which two options you are handling and need to demonstrate correct functioning of the command with respect to (atleast) your chosen options. You also need to handle corner cases such as invalid options (graceful degradation).
2. The second task would be the achieve the above functionality of the shell using pthread create() (instead of fork()) and system() (instead of execl() family of functions). The thread based execution would be performed if the command is followed by the characters, “&t”. The rest of the functionalities should remain the same. Note: you only need one set of external command programs which could be used with either versions of the shell, be it the that uses fork()/execl() or the one that uses pthread create()/system().