Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: update os.markdown #976

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 16 additions & 8 deletions doc/api/os.markdown
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# os
# OS

Stability: 4 - API Frozen

Expand All @@ -8,28 +8,32 @@ Use `require('os')` to access this module.

## os.tmpdir()

Returns the operating system's default directory for temp files.
Returns the operating system's default directory for temporary files.

## os.endianness()

Returns the endianness of the CPU. Possible values are `"BE"` or `"LE"`.
Returns the endianness of the CPU. Possible values are `'BE'` for big endian
or `'LE'` for little endian.

## os.hostname()

Returns the hostname of the operating system.

## os.type()

Returns the operating system name.
Returns the operating system name. For example `'Linux'` on Linux, `'Darwin'`
on OS X and `'Windows_NT'` on Windows.

## os.platform()

Returns the operating system platform.
Returns the operating system platform. Possible values are `'darwin'`,
`'freebsd'`, `'linux'`, `'sunos'` or `'win32'`. Returns the value of
`process.platform`.

## os.arch()

Returns the operating system CPU architecture. Possible values are `"x64"`,
`"arm"` and `"ia32"`.
Returns the operating system CPU architecture. Possible values are `'x64'`,
`'arm'` and `'ia32'`. Returns the value of `process.arch`.

## os.release()

Expand Down Expand Up @@ -132,6 +136,9 @@ Example inspection of os.cpus:
idle: 1072572010,
irq: 30 } } ]

Note that since `nice` values are UNIX centric in Windows the `nice` values of
all processors are always 0.

## os.networkInterfaces()

Get a list of network interfaces:
Expand Down Expand Up @@ -164,4 +171,5 @@ interfaces that have been assigned an address.

## os.EOL

A constant defining the appropriate End-of-line marker for the operating system.
A constant defining the appropriate End-of-line marker for the operating
system.