tgstation-server 6.1.2
The /tg/station 13 server suite
Loading...
Searching...
No Matches
PlatformIdentifier.cs
Go to the documentation of this file.
1using System.Runtime.InteropServices;
2using System.Runtime.Versioning;
3
5{
8 {
10 [SupportedOSPlatformGuard("windows")]
11 public bool IsWindows { get; }
12
14 public string ScriptFileExtension { get; }
15
20 {
21 IsWindows = RuntimeInformation.IsOSPlatform(OSPlatform.Windows);
22 ScriptFileExtension = IsWindows ? "bat" : "sh";
23 }
24 }
25}
PlatformIdentifier()
Initializes a new instance of the PlatformIdentifier class.
bool IsWindows
If the current platform is a Windows platform.
string ScriptFileExtension
The extension of executable script files for the system.
For identifying the current platform.