Skip to content

Commit 6939b0c

Browse files
mureinikaduh95
authored andcommitted
doc: fix the order of process.md sections
Fixes: #58402 PR-URL: #58403 Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Antoine du Hamel <[email protected]>
1 parent 215587f commit 6939b0c

File tree

1 file changed

+45
-45
lines changed

1 file changed

+45
-45
lines changed

doc/api/process.md

Lines changed: 45 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -976,6 +976,24 @@ $ bash -c 'exec -a customArgv0 ./node'
976976
'customArgv0'
977977
```
978978

979+
## `process.availableMemory()`
980+
981+
<!-- YAML
982+
added: v22.0.0
983+
changes:
984+
- version: v22.16.0
985+
pr-url: https://github.com/nodejs/node/pull/57765
986+
description: Change stability index for this feature from Experimental to Stable.
987+
-->
988+
989+
* {number}
990+
991+
Gets the amount of free memory that is still available to the process
992+
(in bytes).
993+
994+
See [`uv_get_available_memory`][uv_get_available_memory] for more
995+
information.
996+
979997
## `process.channel`
980998

981999
<!-- YAML
@@ -1147,24 +1165,6 @@ is unknown, `0` is returned.
11471165
See [`uv_get_constrained_memory`][uv_get_constrained_memory] for more
11481166
information.
11491167

1150-
## `process.availableMemory()`
1151-
1152-
<!-- YAML
1153-
added: v22.0.0
1154-
changes:
1155-
- version: v22.16.0
1156-
pr-url: https://github.com/nodejs/node/pull/57765
1157-
description: Change stability index for this feature from Experimental to Stable.
1158-
-->
1159-
1160-
* {number}
1161-
1162-
Gets the amount of free memory that is still available to the process
1163-
(in bytes).
1164-
1165-
See [`uv_get_available_memory`][uv_get_available_memory] for more
1166-
information.
1167-
11681168
## `process.cpuUsage([previousValue])`
11691169

11701170
<!-- YAML
@@ -1766,6 +1766,33 @@ that started the Node.js process. Symbolic links, if any, are resolved.
17661766
'/usr/local/bin/node'
17671767
```
17681768
1769+
## `process.execve(file[, args[, env]])`
1770+
1771+
<!-- YAML
1772+
added: v22.15.0
1773+
-->
1774+
1775+
> Stability: 1 - Experimental
1776+
1777+
* `file` {string} The name or path of the executable file to run.
1778+
* `args` {string\[]} List of string arguments. No argument can contain a null-byte (`\u0000`).
1779+
* `env` {Object} Environment key-value pairs.
1780+
No key or value can contain a null-byte (`\u0000`).
1781+
**Default:** `process.env`.
1782+
1783+
Replaces the current process with a new process.
1784+
1785+
This is achieved by using the `execve` POSIX function and therefore no memory or other
1786+
resources from the current process are preserved, except for the standard input,
1787+
standard output and standard error file descriptor.
1788+
1789+
All other resources are discarded by the system when the processes are swapped, without triggering
1790+
any exit or close events and without running any cleanup handler.
1791+
1792+
This function will never return, unless an error occurred.
1793+
1794+
This function is not available on Windows or IBM i.
1795+
17691796
## `process.exit([code])`
17701797
17711798
<!-- YAML
@@ -3322,33 +3349,6 @@ In custom builds from non-release versions of the source tree, only the
33223349
`name` property may be present. The additional properties should not be
33233350
relied upon to exist.
33243351
3325-
## `process.execve(file[, args[, env]])`
3326-
3327-
<!-- YAML
3328-
added: v22.15.0
3329-
-->
3330-
3331-
> Stability: 1 - Experimental
3332-
3333-
* `file` {string} The name or path of the executable file to run.
3334-
* `args` {string\[]} List of string arguments. No argument can contain a null-byte (`\u0000`).
3335-
* `env` {Object} Environment key-value pairs.
3336-
No key or value can contain a null-byte (`\u0000`).
3337-
**Default:** `process.env`.
3338-
3339-
Replaces the current process with a new process.
3340-
3341-
This is achieved by using the `execve` POSIX function and therefore no memory or other
3342-
resources from the current process are preserved, except for the standard input,
3343-
standard output and standard error file descriptor.
3344-
3345-
All other resources are discarded by the system when the processes are swapped, without triggering
3346-
any exit or close events and without running any cleanup handler.
3347-
3348-
This function will never return, unless an error occurred.
3349-
3350-
This function is not available on Windows or IBM i.
3351-
33523352
## `process.report`
33533353
33543354
<!-- YAML

0 commit comments

Comments
 (0)