@rtorcato/js-common / os
os
Functions
getOsRelease()
getOsRelease():
string|undefined
Defined in: os/index.ts:11
Returns the OS release/version (Node.js only).
Example
getOsRelease() // 'node'
Returns
string | undefined
getOsArch()
getOsArch():
string|undefined
Defined in: os/index.ts:27
Returns the OS architecture (Node.js only).
Example
getOsArch() // 'arm64' on Apple silicon, 'x64' on Intel
Returns
string | undefined
getHomeDir()
getHomeDir():
string|undefined
Defined in: os/index.ts:36
Returns the user's home directory (Node.js only).
Returns
string | undefined
getTmpDir()
getTmpDir():
string|undefined
Defined in: os/index.ts:48
Returns the system's temporary directory (Node.js only).
Returns
string | undefined