work to make documentation unified.

This commit is contained in:
Olivier Gagnon
2021-03-12 02:51:56 -05:00
parent a00c253dcb
commit 2ce6ff2041
176 changed files with 1325 additions and 916 deletions

View File

@@ -1,24 +1,30 @@
scriptRunning() Netscript Function
==================================
.. js:function:: scriptRunning(scriptname, hostname/ip)
.. js:function:: scriptRunning(scriptname, hostname)
:param string scriptname: Filename of script to check. This is case-sensitive.
:param string hostname/ip: Hostname or IP of target server
:RAM cost: 1 GB
:param string scriptname: Filename of script to check. case-sensitive.
:param string hostname: Hostname of target server.
:returns: ``true`` if any script with that file name is running on that
server.
Returns a boolean indicating whether any instance of the specified script is running on the target server, regardless of
its arguments.
This is different than the :doc:`isRunning<isRunning>` function because it
does not try to identify a specific instance of a running script by its
arguments.
This is different than the *isRunning()* function because it does not try to identify a specific instance of a running script
by its arguments.
Examples:
**Examples:**
The example below will return true if there is any script named
``foo.script`` running on the ``foodnstuff`` server, and false otherwise:
The example below will return true if there is any script named *foo.script* running on the *foodnstuff* server, and false otherwise::
.. code-block:: javascript
scriptRunning("foo.script", "foodnstuff");
The example below will return true if there is any script named "foo.script" running on the current server, and false otherwise::
The example below will return true if there is any script named
``foo.script`` running on the current server, and false otherwise:
.. code-block:: javascript
scriptRunning("foo.script", getHostname());