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: format Unix consistently #28576

Merged
merged 1 commit into from
Jul 8, 2019
Merged
Show file tree
Hide file tree
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
16 changes: 8 additions & 8 deletions doc/api/child_process.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ changes:
* `encoding` {string} **Default:** `'utf8'`
* `shell` {string} Shell to execute the command with. See
[Shell Requirements][] and [Default Windows Shell][]. **Default:**
`'/bin/sh'` on UNIX, `process.env.ComSpec` on Windows.
`'/bin/sh'` on Unix, `process.env.ComSpec` on Windows.
* `timeout` {number} **Default:** `0`
* `maxBuffer` {number} Largest amount of data in bytes allowed on stdout or
stderr. If exceeded, the child process is terminated and any output is
Expand Down Expand Up @@ -260,7 +260,7 @@ changes:
* `windowsVerbatimArguments` {boolean} No quoting or escaping of arguments is
done on Windows. Ignored on Unix. **Default:** `false`.
* `shell` {boolean|string} If `true`, runs `command` inside of a shell. Uses
`'/bin/sh'` on UNIX, and `process.env.ComSpec` on Windows. A different
`'/bin/sh'` on Unix, and `process.env.ComSpec` on Windows. A different
shell can be specified as a string. See [Shell Requirements][] and
[Default Windows Shell][]. **Default:** `false` (no shell).
* `callback` {Function} Called with the output when process terminates.
Expand Down Expand Up @@ -411,7 +411,7 @@ changes:
* `uid` {number} Sets the user identity of the process (see setuid(2)).
* `gid` {number} Sets the group identity of the process (see setgid(2)).
* `shell` {boolean|string} If `true`, runs `command` inside of a shell. Uses
`'/bin/sh'` on UNIX, and `process.env.ComSpec` on Windows. A different
`'/bin/sh'` on Unix, and `process.env.ComSpec` on Windows. A different
shell can be specified as a string. See [Shell Requirements][] and
[Default Windows Shell][]. **Default:** `false` (no shell).
* `windowsVerbatimArguments` {boolean} No quoting or escaping of arguments is
Expand Down Expand Up @@ -666,7 +666,7 @@ child registers an event handler for the [`'disconnect'`][] event
or the [`'message'`][] event. This allows the child to exit
normally without the process being held open by the open IPC channel.*

On UNIX-like operating systems, the [`child_process.spawn()`][] method
On Unix-like operating systems, the [`child_process.spawn()`][] method
performs memory operations synchronously before decoupling the event loop
from the child. Applications with a large memory footprint may find frequent
[`child_process.spawn()`][] calls to be a bottleneck. For more information,
Expand Down Expand Up @@ -729,7 +729,7 @@ changes:
* `windowsHide` {boolean} Hide the subprocess console window that would
normally be created on Windows systems. **Default:** `false`.
* `shell` {boolean|string} If `true`, runs `command` inside of a shell. Uses
`'/bin/sh'` on UNIX, and `process.env.ComSpec` on Windows. A different
`'/bin/sh'` on Unix, and `process.env.ComSpec` on Windows. A different
shell can be specified as a string. See [Shell Requirements][] and
[Default Windows Shell][]. **Default:** `false` (no shell).
* Returns: {Buffer|string} The stdout from the command.
Expand Down Expand Up @@ -780,7 +780,7 @@ changes:
* `env` {Object} Environment key-value pairs.
* `shell` {string} Shell to execute the command with. See
[Shell Requirements][] and [Default Windows Shell][]. **Default:**
`'/bin/sh'` on UNIX, `process.env.ComSpec` on Windows.
`'/bin/sh'` on Unix, `process.env.ComSpec` on Windows.
* `uid` {number} Sets the user identity of the process. (See setuid(2)).
* `gid` {number} Sets the group identity of the process. (See setgid(2)).
* `timeout` {number} In milliseconds the maximum amount of time the process
Expand Down Expand Up @@ -858,7 +858,7 @@ changes:
* `encoding` {string} The encoding used for all stdio inputs and outputs.
**Default:** `'buffer'`.
* `shell` {boolean|string} If `true`, runs `command` inside of a shell. Uses
`'/bin/sh'` on UNIX, and `process.env.ComSpec` on Windows. A different
`'/bin/sh'` on Unix, and `process.env.ComSpec` on Windows. A different
shell can be specified as a string. See [Shell Requirements][] and
[Default Windows Shell][]. **Default:** `false` (no shell).
* `windowsVerbatimArguments` {boolean} No quoting or escaping of arguments is
Expand Down Expand Up @@ -1255,7 +1255,7 @@ can be handled by the parent and some by the child.
While the example above uses a server created using the `net` module, `dgram`
module servers use exactly the same workflow with the exceptions of listening on
a `'message'` event instead of `'connection'` and using `server.bind()` instead
of `server.listen()`. This is, however, currently only supported on UNIX
of `server.listen()`. This is, however, currently only supported on Unix
platforms.

#### Example: sending a socket object
Expand Down
2 changes: 1 addition & 1 deletion doc/api/cluster.md
Original file line number Diff line number Diff line change
Expand Up @@ -589,7 +589,7 @@ The `addressType` is one of:

* `4` (TCPv4)
* `6` (TCPv6)
* `-1` (unix domain socket)
* `-1` (Unix domain socket)
* `'udp4'` or `'udp6'` (UDP v4 or v6)

## Event: 'message'
Expand Down
2 changes: 1 addition & 1 deletion doc/api/fs.md
Original file line number Diff line number Diff line change
Expand Up @@ -847,7 +847,7 @@ The times in the stat object have the following semantics:
* `birthtime` "Birth Time" - Time of file creation. Set once when the
file is created. On filesystems where birthtime is not available,
this field may instead hold either the `ctime` or
`1970-01-01T00:00Z` (ie, unix epoch timestamp `0`). This value may be greater
`1970-01-01T00:00Z` (ie, Unix epoch timestamp `0`). This value may be greater
than `atime` or `mtime` in this case. On Darwin and other FreeBSD variants,
also set if the `atime` is explicitly set to an earlier value than the current
`birthtime` using the utimes(2) system call.
Expand Down
20 changes: 10 additions & 10 deletions doc/api/net.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,34 +17,34 @@ const net = require('net');

## IPC Support

The `net` module supports IPC with named pipes on Windows, and UNIX domain
The `net` module supports IPC with named pipes on Windows, and Unix domain
sockets on other operating systems.

### Identifying paths for IPC connections

[`net.connect()`][], [`net.createConnection()`][], [`server.listen()`][] and
[`socket.connect()`][] take a `path` parameter to identify IPC endpoints.

On UNIX, the local domain is also known as the UNIX domain. The path is a
On Unix, the local domain is also known as the Unix domain. The path is a
filesystem pathname. It gets truncated to `sizeof(sockaddr_un.sun_path) - 1`,
which varies on different operating system between 91 and 107 bytes.
The typical values are 107 on Linux and 103 on macOS. The path is
subject to the same naming conventions and permissions checks as would be done
on file creation. If the UNIX domain socket (that is visible as a file system
on file creation. If the Unix domain socket (that is visible as a file system
path) is created and used in conjunction with one of Node.js' API abstractions
such as [`net.createServer()`][], it will be unlinked as part of
[`server.close()`][]. On the other hand, if it is created and used outside of
these abstractions, the user will need to manually remove it. The same applies
when the path was created by a Node.js API but the program crashes abruptly.
In short, a UNIX domain socket once successfully created will be visible in the
In short, a Unix domain socket once successfully created will be visible in the
filesystem, and will persist until unlinked.

On Windows, the local domain is implemented using a named pipe. The path *must*
refer to an entry in `\\?\pipe\` or `\\.\pipe\`. Any characters are permitted,
but the latter may do some processing of pipe names, such as resolving `..`
sequences. Despite how it might look, the pipe namespace is flat. Pipes will
*not persist*. They are removed when the last reference to them is closed.
Unlike UNIX domain sockets, Windows will close and remove the pipe when the
Unlike Unix domain sockets, Windows will close and remove the pipe when the
owning process exits.

JavaScript string escaping requires paths to be specified with extra backslash
Expand Down Expand Up @@ -121,7 +121,7 @@ as reported by the operating system if listening on an IP socket
(useful to find which port was assigned when getting an OS-assigned address):
`{ port: 12346, family: 'IPv4', address: '127.0.0.1' }`.

For a server listening on a pipe or UNIX domain socket, the name is returned
For a server listening on a pipe or Unix domain socket, the name is returned
as a string.

```js
Expand Down Expand Up @@ -241,7 +241,7 @@ added: v0.5.10
* Returns: {net.Server}

Start a server listening for connections on a given `handle` that has
already been bound to a port, a UNIX domain socket, or a Windows named pipe.
already been bound to a port, a Unix domain socket, or a Windows named pipe.

The `handle` object can be either a server, a socket (anything with an
underlying `_handle` member), or an object with an `fd` member that is a
Expand Down Expand Up @@ -385,7 +385,7 @@ added: v0.3.4
-->

This class is an abstraction of a TCP socket or a streaming [IPC][] endpoint
(uses named pipes on Windows, and UNIX domain sockets otherwise). A
(uses named pipes on Windows, and Unix domain sockets otherwise). A
`net.Socket` is also a [duplex stream][], so it can be both readable and
writable, and it is also an [`EventEmitter`][].

Expand Down Expand Up @@ -496,7 +496,7 @@ changes:
-->

Emitted after resolving the hostname but before connecting.
Not applicable to UNIX sockets.
Not applicable to Unix sockets.

* `err` {Error|null} The error object. See [`dns.lookup()`][].
* `address` {string} The IP address.
Expand Down Expand Up @@ -1112,7 +1112,7 @@ server.listen('/tmp/echo.sock', () => {
});
```

Use `nc` to connect to a UNIX domain socket server:
Use `nc` to connect to a Unix domain socket server:

```console
$ nc -U /tmp/echo.sock
Expand Down
4 changes: 2 additions & 2 deletions doc/api/os.md
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ The properties included on each object include:
]
```

Because `nice` values are UNIX-specific, on Windows the `nice` values of all
Because `nice` values are Unix-specific, on Windows the `nice` values of all
processors are always 0.

## os.endianness()
Expand Down Expand Up @@ -239,7 +239,7 @@ The load average is a measure of system activity, calculated by the operating
system and expressed as a fractional number. As a rule of thumb, the load
average should ideally be less than the number of logical CPUs in the system.

The load average is a UNIX-specific concept with no real equivalent on
The load average is a Unix-specific concept with no real equivalent on
Windows platforms. On Windows, the return value is always `[0, 0, 0]`.

## os.networkInterfaces()
Expand Down
2 changes: 1 addition & 1 deletion doc/api/tls.md
Original file line number Diff line number Diff line change
Expand Up @@ -1207,7 +1207,7 @@ changes:
* `host` {string} Host the client should connect to. **Default:**
`'localhost'`.
* `port` {number} Port the client should connect to.
* `path` {string} Creates unix socket connection to path. If this option is
* `path` {string} Creates Unix socket connection to path. If this option is
specified, `host` and `port` are ignored.
* `socket` {stream.Duplex} Establish secure connection on a given socket
rather than creating a new socket. Typically, this is an instance of
Expand Down