Interface IPlatform
- Namespace
- FishMMO.Installer
- Assembly
- FishMMO-Installer.dll
Abstracts OS-specific operations so installer components don't scatter IsOSPlatform(OSPlatform) checks everywhere.
public interface IPlatform
Properties
IsLinux
True when running on Linux.
bool IsLinux { get; }
Property Value
IsWindows
True when running on Windows.
bool IsWindows { get; }
Property Value
Methods
GetShellCommand()
Returns the OS-appropriate shell executable and argument prefix. Windows: (cmd.exe, /c). Linux: fish if available, else bash.
(string shell, string argPrefix) GetShellCommand()
Returns
IsCommandAvailableAsync(string)
Checks whether a given executable is available on PATH.
Task<bool> IsCommandAvailableAsync(string command)
Parameters
commandstring