All files and directories are reset on every boot. RAMFS does not persist data across reboots.
Filesystem limits
The following constants define the hard limits of the RAMFS implementation (frominclude/mvh/fs.h):
ls
List the contents of a directory. Syntaxpath, the current working directory is listed. Directories are shown with a [DIR] prefix in blue; files are shown with [FILE] and their size in bytes.
Example
dir
Alias forls. Accepts the same optional path argument and produces identical output.
Syntax
cd
Change the current working directory. Both relative and absolute paths are supported. Runningcd without an argument changes to /home.
Syntax
cd: directory not found.
pwd
Print the current working directory as an absolute path. Syntaxmkdir
Create a new directory at the given path. Parent directories must already exist. Syntaxmkdir: cannot create directory.
touch
Create a new empty file. If the file already exists, the command succeeds without modifying its contents. Syntaxwrite
Write text to a file, replacing any existing content. If the file does not already exist, it is created automatically. The entire argument after the filename is treated as the text to write. Syntaxwrite: file is full.
append
Append text to an existing file without removing previous content. If the file does not exist, it is created first. The total file size must remain withinFS_DATA_MAX (256 bytes).
Syntax
cat
Print the full contents of a file to the shell. Syntaxcat: file not found.
type
Alias forcat. Accepts the same path argument and produces identical output.
Syntax
open
Open a file and print its contents. Behaves identically tocat.
Syntax
rm
Remove a file from the filesystem. The path must point to an existing file, not a directory. Syntaxrm: path not found. If you attempt to remove a non-empty directory, the shell prints rm: directory is not empty.
rmdir
Remove a directory. The directory must be empty before removal.rmdir is an alias that calls the same underlying removal function as rm.
Syntax
rmdir: directory is not empty.
mount
List all currently mounted filesystems. In the current release, RAMFS is the only filesystem and is always mounted at/.
Syntax