Back to Portfolio

Unix FS Emulator

A memory-resident N-ary tree filesystem emulator that mimics the behavior of a Unix-like filesystem.

View on GitHub

Project Diagram

N-ary Tree Filesystem

About The Project

The Unix FS Emulator is a C-based project that implements a memory-resident filesystem using an N-ary tree. It provides a simplified model of a Unix-like filesystem, with support for common commands like `mkdir`, `ls`, `cd`, and `touch`.

Key Features

  • Memory-Resident: The filesystem is stored entirely in memory, making it extremely fast.
  • N-ary Tree Implementation: The filesystem is implemented as an N-ary tree, which is a natural way to represent a hierarchical directory structure.
  • Unix-like Commands: The emulator supports a subset of common Unix filesystem commands.

Technical Details

The core of the project is the `FileSystem` class, which manages the N-ary tree. Each node in the tree represents a file or directory. The class provides methods for creating, deleting, and navigating the filesystem. The command-line interface is implemented in a separate module that parses user input and calls the appropriate `FileSystem` methods.