Academic Project — 2024
IIUI Mini Shell is a lightweight command-line shell built from scratch in Python, designed to provide essential shell functionality while exploring concepts such as command parsing, process execution, filesystem operations, pipes, I/O redirection, and command history.
Includes 20+ built-in commands for everyday shell operations:
| Command | Description |
|---|---|
cd |
Change directory |
pwd |
Show current directory |
ls / dir |
List files and directories |
mkdir |
Create directories |
rmdir |
Remove empty directories |
touch |
Create files |
rm / del |
Remove files or directories |
cat / type |
Display file contents |
echo |
Print text |
clear / cls |
Clear terminal |
history |
View command history |
whoami |
Display current username |
which / where |
Locate commands |
date |
Display date and time |
tree |
Display directory structure |
help |
Show command reference |
about |
Display shell information |
exit / quit |
Exit the shell |
- Saves command history between sessions
- Navigate previously entered commands using arrow keys
- Auto-complete available commands with
Tab - Complete file and directory names
Supports piping the output of one command into another:
command1 | command2Supports redirecting command input and output:
command > output.txt
command >> output.txt
command < input.txtRun commands without blocking the shell:
command &Designed to work across Windows, Linux, and macOS, with platform-specific command aliases such as dir/ls and cls/clear.
- Python
subprocessosshutilreadline/ platform-specific input handling- PyInstaller for executable packaging
git clone https://github.com/aamnamz/IIUI-Mini-Shell.git
cd IIUI-Mini-Shellpython main.pyThe project can be packaged as a standalone Windows executable using PyInstaller, allowing the shell to run without requiring a Python installation.
pyinstaller --onefile main.pyThe generated executable will be available in the dist/ directory.
IIUI Mini Shell was built to explore how command-line shells work internally, including:
- Command parsing and execution
- Process management
- Filesystem operations
- Inter-process communication
- Pipes and I/O redirection
- Persistent command history
- Cross-platform system interaction
Completed — standalone shell with cross-platform functionality and Windows executable support.
Amna Mumtaz
