CLIMaster is a terminal-based simulation project that mimics an operating system environment using C programming language. The project focuses on file system management, directory navigation, and file manipulation commands like mkdir, ls, cd, createfile, cat, and more. It provides a basic terminal interface for users to interact with files and directories, making it a great learning tool for understanding file systems and OS concepts.
- File System Simulation: Create and manage files within directories.
- Directory Navigation: Navigate through directories using
cdand list contents withls. - File Operations: Create, display, write, and delete files using
createfile,cat,echo, andremove. - Built-in Help: View available commands with the
helpcommand.
Below are the commands supported by CLIMaster:
- ls: Lists the files and directories in the current directory.
- mkdir <dir_name>: Creates a new directory.
- cd <dir_name>: Changes the current directory to the specified one.
- createfile <file_name>: Creates a new empty file.
- cat <file_name>: Displays the content of a file.
- echo <file_name>: Appends text to an existing file.
- remove <file_name>: Removes a file.
- help: Displays the list of available commands.
- exit: Exits the terminal simulation.
To get started with CLIMaster:
-
Clone the repository to your local machine:
git clone https://github.com/yourusername/CLIMaster.git
-
Navigate into the project directory:
cd CLIMaster -
Compile the project using GCC:
gcc -o climaster main.c
-
Run the program:
./climaster
Once the program is running, you will be prompted with a terminal interface where you can use the commands listed above to interact with the simulated file system.
root$ ls
Files:
- about.txt
- projects.txt
Directories:
- projects
- files
root$ mkdir mydir
Directory 'mydir' created.
root$ cd mydir
Moved up to 'root'.
root$ ls
Files:
Directories:
- mydir