mirror of
https://github.com/Leonmmcoset/CMLeonOS.git
synced 2026-03-03 15:30:27 +00:00
lua快捷运行
This commit is contained in:
@@ -407,6 +407,22 @@ namespace CMLeonOS
|
||||
string expandedCommand = command;
|
||||
string expandedArgs = args;
|
||||
|
||||
if (command.StartsWith(":"))
|
||||
{
|
||||
string appName = command.Substring(1);
|
||||
string appPath = "0:\\apps\\" + appName + ".lua";
|
||||
|
||||
if (System.IO.File.Exists(appPath))
|
||||
{
|
||||
Commands.Script.LuaCommand.ExecuteLuaScript(appPath, fileSystem, this, ShowError, ShowWarning);
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowError($"App not found: {appName}");
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
string aliasValue = Commands.AliasCommand.GetAlias(command);
|
||||
if (aliasValue != null)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user