mirror of
https://github.com/binaricat/Netcatty.git
synced 2026-11-27 20:00:51 +00:00
27 lines
785 B
TypeScript
27 lines
785 B
TypeScript
import {
|
|
classifyLocalShellType as classifySharedLocalShellType,
|
|
detectLocalOs as detectSharedLocalOs,
|
|
isDiscoveredGitBash as isSharedDiscoveredGitBash,
|
|
} from "@/lib/localShell.cjs";
|
|
|
|
export type LocalShellType = "posix" | "fish" | "powershell" | "cmd" | "unknown";
|
|
export type LocalOs = "linux" | "macos" | "windows";
|
|
|
|
export function detectLocalOs(platformLike?: string): LocalOs {
|
|
return detectSharedLocalOs(platformLike);
|
|
}
|
|
|
|
export function classifyLocalShellType(
|
|
shellPath: string | undefined,
|
|
platformLike?: string,
|
|
): LocalShellType {
|
|
return classifySharedLocalShellType(shellPath, platformLike);
|
|
}
|
|
|
|
export function isDiscoveredGitBash(
|
|
shell?: string,
|
|
discoveredCommand?: string,
|
|
): boolean {
|
|
return isSharedDiscoveredGitBash(shell, discoveredCommand);
|
|
}
|