code/modules/networks/computer3/mainframe2/_base_os.dm
ESIG_SUCCESS | The command was carried out successfully. |
---|---|
ESIG_GENERIC | The command could not be carried out successfully. |
ESIG_NOTARGET | The command could not be carried out successfully, as a target was required and could not be found. |
ESIG_BADCOMMAND | The command could not be carried out successfully, as the command was not recognised. |
ESIG_NOUSR | The command could not be carried out successfully, as a user was required and could not be found. |
ESIG_IOERR | The command could not be carried out successfully, as a result of an I/O error. |
ESIG_NOFILE | The command could not be carried out successfully, as a file was required and could not be found. |
ESIG_NOWRITE | The command could not be carried out successfully, as write permission was required. |
ESIG_USR1 | User defined signal 1. This indicates an application-specific error condition has occured. |
ESIG_USR2 | User defined signal 2. This indicates an application-specific error condition has occured. |
ESIG_USR3 | User defined signal 3. This indicates an application-specific error condition has occured. |
ESIG_USR4 | User defined signal 4. This indicates an application-specific error condition has occured. |
ESIG_DATABIT | If a command is expected to return a number, it will be signed with the databit to signify that it is not an error condition. |
DWAINE_COMMAND_MSG_TERM | Send a message or file to a connected terminal device. Accepted data fields: |
DWAINE_COMMAND_ULOGIN | Send a log in request to the kernel. Accepted data fields: |
DWAINE_COMMAND_UGROUP | Update the user's group. Accepted data fields: |
DWAINE_COMMAND_ULIST | List all current users. No applicable data fields. |
DWAINE_COMMAND_UMSG | Send message to a connected user terminal. Cannot send messages to non-user terminals. Accepted data fields: |
DWAINE_COMMAND_UINPUT | Acts as an alternate path for user input. Accepted data fields: |
DWAINE_COMMAND_DMSG | Send message to a specified driver. Accepted data fields: |
DWAINE_COMMAND_DLIST | List all drivers of a specific terminal type. Accepted data fields: |
DWAINE_COMMAND_DGET | Get the ID of a specific driver. Accepted data fields: |
DWAINE_COMMAND_DSCAN | Instruct the mainframe to recheck for devices now instead of waiting for the full timeout. No applicable data fields. |
DWAINE_COMMAND_EXIT | Instruct the caller to exit the current running program. No applicable data fields. |
DWAINE_COMMAND_TSPAWN | Run a task located at a specified filepath. Accepted data fields: |
DWAINE_COMMAND_TFORK | Run a new child task of the calling program's type. Accepted data fields: |
DWAINE_COMMAND_TKILL | Terminate a child task of the calling program. Accepted data fields: |
DWAINE_COMMAND_TLIST | List all child tasks of the calling program. No applicable data fields. |
DWAINE_COMMAND_TEXIT | Instruct a program to exit the current running task. No applicable data fields. |
DWAINE_COMMAND_FGET | Get the computer file at the specified filepath. Accepted data fields: |
DWAINE_COMMAND_FKILL | Delete the computer file at the specified filepath. Accepted data fields: |
DWAINE_COMMAND_FMODE | Adjust the permissions of the computer file at the specified filepath. Accepted data fields: |
DWAINE_COMMAND_FOWNER | Adjust the owner and group of the computer file at the specified filepath. Accepted data fields: |
DWAINE_COMMAND_FWRITE | Write a provided computer file to the specified path. Accepted data fields: |
DWAINE_COMMAND_CONFGET | Get the config file of the specified name. Accepted data fields: |
DWAINE_COMMAND_MOUNT | Set up a mountpoint for a device driver. Accepted data fields: |
DWAINE_COMMAND_RECVFILE | Instruct a program to receive and handle a file. No applicable data fields. |
DWAINE_COMMAND_BREAK | Instruct a program to halt processing a script. No applicable data fields. |
DWAINE_COMMAND_REPLY | Reply to a request for information. Has unique data fields for each implementation, depending on the data requested. |
/var/generic_exit_list | Global list representing the standard exit command packet. |
mainframe_prog_exit | Exit the current running program. |
setup_filepath_users | Filepath that corresponds to the directory for user record files. |
setup_filepath_users_home | Filepath that corresponds to the directory for personal user directories. |
setup_filepath_drivers | Filepath that corresponds to the directory for device and pseudo-device files. |
setup_filepath_drivers_proto | Filepath that corresponds to the directory for device file prototypes. Prototypes are named after the ID of their respective device, excluding the "pnet_" prefix. |
setup_filepath_volumes | Filepath that corresponds to the directory for mounted file systems, such as databanks. |
setup_filepath_system | Filepath that corresponds to the directory for the OS, including the kernel, shell, and login program. |
setup_filepath_config | Filepath that corresponds to the directory for configuration files. |
setup_filepath_commands | Filepath that corresponds to the directory for binaries (executable files). It contains fundamental system utilities, including system commands, such as ls or cd . |
setup_filepath_process | Filepath that corresponds to the directory for information files pertaining to active processes. |
/datum/computer/file/mainframe_program/os/kernel | The kernel is the computer program at the core of the OS and is responsible for managing interactions with all hardware devices, such as terminals, databanks, scanners and so forth through device drivers; for handling inputs; for creating and terminating connections; for the execution of system calls; and for other basic system services. |
/datum/computer/file/mainframe_program/login | The user login manager is responsible for passing user login credentials from the user to the kernel to be authenticated, displaying the daily welcome message to the user, and for notifying the user in the event of a login failure. |
Define Details
DWAINE_COMMAND_BREAK
Instruct a program to halt processing a script. No applicable data fields.
DWAINE_COMMAND_CONFGET
Get the config file of the specified name. Accepted data fields:
"fname"
: The name of the config file.
DWAINE_COMMAND_DGET
Get the ID of a specific driver. Accepted data fields:
"dtag"
: The terminal type of the drivers to search for."dnetid"
: If"dtag"
is not specified, the driver name to search for. Driver names correspond to the net ID of their respective device, excluding the "pnet_" prefix.
DWAINE_COMMAND_DLIST
List all drivers of a specific terminal type. Accepted data fields:
"dtag"
: The terminal type of the drivers to search for."mode"
: If1
, omit empty or invalid indexes, if0
, do not.
DWAINE_COMMAND_DMSG
Send message to a specified driver. Accepted data fields:
"target"
: The name or ID of the target driver."mode"
: If1
, search for drivers by name, if0
, search by ID."dcommand"
: The"command"
field to pass to the driver."dtarget"
: The"target"
field to pass to the driver.
DWAINE_COMMAND_DSCAN
Instruct the mainframe to recheck for devices now instead of waiting for the full timeout. No applicable data fields.
DWAINE_COMMAND_EXIT
Instruct the caller to exit the current running program. No applicable data fields.
DWAINE_COMMAND_FGET
Get the computer file at the specified filepath. Accepted data fields:
"path"
: The filepath at which the computer file is located.
DWAINE_COMMAND_FKILL
Delete the computer file at the specified filepath. Accepted data fields:
"path"
: The filepath at which the computer file is located.
DWAINE_COMMAND_FMODE
Adjust the permissions of the computer file at the specified filepath. Accepted data fields:
"path"
: The filepath at which the computer file is located."permission"
: The desired permission level of the computer file.
DWAINE_COMMAND_FOWNER
Adjust the owner and group of the computer file at the specified filepath. Accepted data fields:
"path"
: The filepath at which the computer file is located."owner"
: The desired owner of the computer file."group"
: The desired group value of the computer file.
DWAINE_COMMAND_FWRITE
Write a provided computer file to the specified path. Accepted data fields:
"path"
: The filepath at which the computer file should be written to."mkdir"
: Whether to create the filepath if it does not exist."replace"
: If the computer file already exists, whether to overwrite it."append"
: If the computer file already exists, whether to append the contents of the new file to it.
DWAINE_COMMAND_MOUNT
Set up a mountpoint for a device driver. Accepted data fields:
"id"
: The name of the device driver to set up a mountpoint for."link"
: If set, the name of the symbolic link folder to set up for the mountpoint.
DWAINE_COMMAND_MSG_TERM
Send a message or file to a connected terminal device. Accepted data fields:
"term"
: The net ID of the target terminal."data"
: If sending a message, the content of that message. Otherwise acts as file data."render"
: If sending a message, determines how that message should be displayed. Values may be combined using|
. Accepted values:"clear"
: The screen should be cleared before the message is displayed."multiline"
:|n
should be interpreted as a line break.
DWAINE_COMMAND_RECVFILE
Instruct a program to receive and handle a file. No applicable data fields.
DWAINE_COMMAND_REPLY
Reply to a request for information. Has unique data fields for each implementation, depending on the data requested.
DWAINE_COMMAND_TEXIT
Instruct a program to exit the current running task. No applicable data fields.
DWAINE_COMMAND_TFORK
Run a new child task of the calling program's type. Accepted data fields:
"args"
: The arguments to pass to the task.
DWAINE_COMMAND_TKILL
Terminate a child task of the calling program. Accepted data fields:
"target"
: The ID of the target task.
DWAINE_COMMAND_TLIST
List all child tasks of the calling program. No applicable data fields.
DWAINE_COMMAND_TSPAWN
Run a task located at a specified filepath. Accepted data fields:
"path"
: The filepath at which the task is located."passusr"
: Whether to pass the user to the task."args"
: The arguments to pass to the task.
DWAINE_COMMAND_UGROUP
Update the user's group. Accepted data fields:
"group"
: The desired value of thegroup
field on the user's record file.
DWAINE_COMMAND_UINPUT
Acts as an alternate path for user input. Accepted data fields:
"term"
: The net ID of the user terminal."data"
: If a file is not provided, the content of the input.
DWAINE_COMMAND_ULIST
List all current users. No applicable data fields.
DWAINE_COMMAND_ULOGIN
Send a log in request to the kernel. Accepted data fields:
"name"
: The username of the user attempting to log in. Set to"TEMP"
if attempting to login as a temporary user."sysop"
: Whether the user is a superuser."service"
: Whether the user connecting is a service terminal."data"
: If attempting to login as a temporary user, the net ID of the user terminal.
DWAINE_COMMAND_UMSG
Send message to a connected user terminal. Cannot send messages to non-user terminals. Accepted data fields:
"term"
: The net ID of the target user terminal."data"
: The content of the message.
ESIG_BADCOMMAND
The command could not be carried out successfully, as the command was not recognised.
ESIG_DATABIT
If a command is expected to return a number, it will be signed with the databit to signify that it is not an error condition.
ESIG_GENERIC
The command could not be carried out successfully.
ESIG_IOERR
The command could not be carried out successfully, as a result of an I/O error.
ESIG_NOFILE
The command could not be carried out successfully, as a file was required and could not be found.
ESIG_NOTARGET
The command could not be carried out successfully, as a target was required and could not be found.
ESIG_NOUSR
The command could not be carried out successfully, as a user was required and could not be found.
ESIG_NOWRITE
The command could not be carried out successfully, as write permission was required.
ESIG_SUCCESS
The command was carried out successfully.
ESIG_USR1
User defined signal 1. This indicates an application-specific error condition has occured.
ESIG_USR2
User defined signal 2. This indicates an application-specific error condition has occured.
ESIG_USR3
User defined signal 3. This indicates an application-specific error condition has occured.
ESIG_USR4
User defined signal 4. This indicates an application-specific error condition has occured.
mainframe_prog_exit
Exit the current running program.
setup_filepath_commands
Filepath that corresponds to the directory for binaries (executable files). It contains fundamental system utilities, including system commands, such as ls
or cd
.
setup_filepath_config
Filepath that corresponds to the directory for configuration files.
setup_filepath_drivers
Filepath that corresponds to the directory for device and pseudo-device files.
setup_filepath_drivers_proto
Filepath that corresponds to the directory for device file prototypes. Prototypes are named after the ID of their respective device, excluding the "pnet_" prefix.
setup_filepath_process
Filepath that corresponds to the directory for information files pertaining to active processes.
setup_filepath_system
Filepath that corresponds to the directory for the OS, including the kernel, shell, and login program.
setup_filepath_users
Filepath that corresponds to the directory for user record files.
setup_filepath_users_home
Filepath that corresponds to the directory for personal user directories.
setup_filepath_volumes
Filepath that corresponds to the directory for mounted file systems, such as databanks.