setup-dotnet/src/utils.ts

8 lines
261 B
TypeScript
Raw Normal View History

export const IS_WINDOWS = process.platform === 'win32';
export const IS_LINUX = process.platform === 'linux';
2023-05-12 19:07:46 +07:00
export const getPlatform = (): 'windows' | 'linux' | 'mac' => {
if (IS_WINDOWS) return 'windows';
if (IS_LINUX) return 'linux';
return 'mac';
};