Files
CMLeonOS/shell/Commands/FileSystem/CatCommand.cs
2026-02-04 20:13:21 +08:00

20 lines
470 B
C#

using System;
namespace CMLeonOS.Commands.FileSystem
{
public static class CatCommand
{
public static void ProcessCat(CMLeonOS.FileSystem fileSystem, string args, Action<string> showError)
{
if (string.IsNullOrEmpty(args))
{
showError("Please specify a file name");
}
else
{
Console.WriteLine(fileSystem.ReadFile(args));
}
}
}
}