RunScript Icon
RunScript

Script Runner Engine

Core API Hook: Process.Start (PowerShell / python.exe / cmd.exe)

Orchestrate local background tasks by executing custom PowerShell, Python, Batch, AutoHotkey, or VBScript scripts in a silent environment.

Configuration Parameters

Parameter Type Description
Target string Absolute path to script file (.ps1, .py, .bat, .ahk) or raw script code string snippet.
Arguments string Optional arguments passed to the script execution host.
IsSilent boolean If true, hides the console terminal window completely during process execution.

config.json Mapping

{
  "Type": "RunScript",
  "Name": "Clean Temp Files Script",
  "Target": "C:\\Scripts\\clean_temp.ps1",
  "Arguments": "-Force",
  "IsSilent": true
}

Save inside database layout actions configuration map.

Native Execution Hook

// RunScript execution logic
var extension = Path.GetExtension(action.Target).ToLower();
var startInfo = new ProcessStartInfo();
if (extension == ".ps1") {
    startInfo.FileName = "powershell.exe";
    startInfo.Arguments = $"-NoProfile -ExecutionPolicy Bypass -File \"{action.Target}\" {action.Arguments}";
} else if (extension == ".py") {
    startInfo.FileName = "python.exe";
    startInfo.Arguments = $"\"{action.Target}\" {action.Arguments}";
} else {
    startInfo.FileName = action.Target;
    startInfo.Arguments = action.Arguments;
}
startInfo.CreateNoWindow = action.IsSilent;
startInfo.UseShellExecute = !action.IsSilent;
Process.Start(startInfo);

Executed within IsoCore remapping runtime loop.

← Back to Actions Directory IsoKey Module: RunScript