This is a basic shell implementation in C programming language with various functionalities similar to a typical Unix shell. It supports basic system calls, process management, file operations, networking, and more. The shell provides a command-line interface for users to interact with their system.
To install the shell, simply compile the source code provided and run the executable. Ensure you have the necessary libraries installed as mentioned in the compilation instructions.
Use the makefile to generate the terminal binary. Then simply run it.
- The shell prompt displays the username, system name, and current directory address.
- The directory address changes dynamically based on the user's current working directory.
- The shell supports commands separated by ';' or '&' symbols.
- It accounts for random spaces and tabs in user input.
-
Changes the shell's working directory.
-
Supports absolute, relative, and symbolic paths.
-
Special symbols like '~', '.', '..', and '-' are supported.
Command Syntax:
warp [directory]
-
Lists files and directories in specified directories with options for displaying hidden files and extra information.
-
Supports relative and absolute paths.
-
Special symbols like '~', '.', '..', and '-' are supported.
-
Differentiates between files, directories, and executables using color coding.
Command Syntax:
peek [flags] [path/name]
-
Records and retrieves the 15 most recent command statements.
-
Supports executing past commands.
-
Supports purging command history.
Command Syntax:
pastevents [execute <index>] | [purge]
- Executes other system commands present in Bash.
- Supports foreground and background processes.
-
Displays information about a process, including PID, process status, process group, virtual memory, and executable path.
Command Syntax:
proclore [pid]
-
Searches for files/directories in the specified target directory.
-
Supports flags for filtering by file type and for executing a single result.
Command Syntax:
seek [flags] [search] [target_directory]
-
Redirects input and output for commands.
-
Supports '>' (overwrite), '>>' (append), and '<' (input).
Command Syntax:
<command> [<arguments>] [> output_file] [| <command> ...]
-
Passes information between commands.
-
Supports any number of pipes.
Command Syntax:
<command> [<arguments>] [| <command> ...]
-
Supports combining I/O redirection with pipes.
Command Syntax:
<command> [<arguments>] [> output_file] [| <command> ...]
- Lists all running processes spawned by the shell.
- Displays command name, PID, and state.
-
Sends signals to processes.
-
Supports common signals like SIGKILL and SIGTERM.
Command Syntax:
ping <pid> <signal_number>
-
Brings background processes to foreground and vice versa.
Command Syntax:
fg <pid> | bg <pid>
-
Prints the PID of the most recently created process at regular intervals until 'x' is pressed.
Command Syntax:
neonate -n [time_arg]
-
Fetches man pages from http://man.he.net/.
-
Prints the name, synopsis, and description of the specified command.
Command Syntax:
iMan <command_name>
- Paths/names should not contain whitespace characters.
- Certain features like background process handling for user-defined commands are not implemented.
- Assumptions are documented in the README for clarity.