Skip to content

Latest commit

 

History

History
59 lines (50 loc) · 11.6 KB

FEATURES.md

File metadata and controls

59 lines (50 loc) · 11.6 KB

EECS678-Project1 - Features

back
The following table includes all features of Quash and their current completion status.

Tokenizer

Requirement Status Details
Support Quoted Strings Quash shall support single and double quoted strings
Support concated tokens (i.e. | vs ||) Quash shall be able to differentiate between:
A pipe (|) and an or (||)
An async character (&) and an AND (&&)
A redirect character (>) and a redirect append string (>>).
Support comments Quash shall support reading in lines until a # symbol is detected. Anything after a # symbol should be ignored (including the #).
Support single characters Quash shall support the following single characters: ;
Support validating matching quotes Quash shall return a status, normal for success, or an error status if mismatched quotes are detected.
Support printing tokens Quash shall support printing tokens either numbered and 1 per line, or on 1 line seperated by spaces.

Process

Requirement Status Details
Support running commands asynchronously Quash shall support running commands in the foreground (asynchronously)
Support running commands in background Quash shall support running commands in the background (simultaneously)
Support running commands with pipes Quash shall support running commands with piped input/output
Support redirecting output Quash shall support redirecting output (both normally and appending to file) from a command
Support redirecting input Quash shall support redirecting input to command
Support running commands (absolute path) Quash shall support running a command with an absolute path "/bin/ls"
Support running commands (relative path) Quash shall support running a command with a relative path "./a.out"
Support running commands (PATH) Quash shall support running a command from the PATH "ls"
Support inheriting environment variables Quash shall support inheriting environment variables at initialization and passing to child processes
Support checking for completed processes Quash shall support checking for completed background processes and printing message when complete.
Support running custom commands Quash shall support running custom commands (See below)

Commands

Requirement Status Details
Support custom 'home' command Quash shall support a custom 'home' command which shall return a string containing the current user's home directory.
Support custom 'hostname' command Quash shall support a custom 'hostname' command which shall return a string containing the current hostname of the machine.
Support custom 'pwd' command Quash shall support a custom 'pwd' command which shall return a string containing the present working directory.
Support custom 'whoami' command Quash shall support a custom 'whoami' command which shall return a string containing the current user's name.
Support custom 'exit' command Quash shall support a custom 'exit' command which shall exit quash. 'quit' and 'logout' shall be aliases to 'exit'
Support custom 'cd' command Quash shall support a custom 'cd' command which shall change directories to the specified directory. If no directory is specified, change directories to the current user's home directory.
Support custom 'set' command Quash shall support a custom 'set' command which shall set the specified variable to the specified value.
Support custom 'help' command Quash shall support a custom 'help' command which shall print a usage message (similar to if --help or -h command line flags were used).
Support custom 'jobs' command Quash shall support a custom 'jobs' command which shall print the status of all background processes.
Support custom 'kill' command Quash shall support a custom 'kill' command which shall send the specified signal to the specified process

Other Features

Requirement Status Details
Support command line flags Quash shall support command line flags.
Support debug output Quash shall support debug output to stderr and file (via command line flags)
Support usage Quash shall support printing a help message when --help or -h is entered via command line
Support signal handling Quash shall support signal handling of SIGINT. SIGINT shall be passed to current child process. SIGINT shall clear prompt, but have no other effect on quash directly.
Support exiting via CTRL-D Quash shall support exiting quash via CTRL-D (i.e. EOF)
Support inheriting the current environment Quash shall support inheriting the current environment.
Support reading in commands from file Quash shall support reading in arguments from file.

back