New Commands & piped interpreter!
This commit is contained in:
26
TermEngine/Commands/ClearCommand.cs
Normal file
26
TermEngine/Commands/ClearCommand.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using TermApp.Core;
|
||||
|
||||
namespace TermApp.Commands
|
||||
{
|
||||
|
||||
public class ClearCommand : ICommand
|
||||
{
|
||||
|
||||
public string Name => "clear";
|
||||
public string Description => "Clears the Terminal";
|
||||
|
||||
public void Execute(string[] args, string input = null)
|
||||
{
|
||||
|
||||
Console.Clear();
|
||||
if (args.Length != 0)
|
||||
{
|
||||
if (args[0] == "log") Console.WriteLine("Cleared :)");
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user