Operating System Operations
Functions
.os.sleep
Suspends execution for a specified number of milliseconds.
| Parameters | Type | Description |
|---|---|---|
| ms | i64 | Number of milliseconds to sleep |
.os.glob
Expands a glob pattern and returns file information as a DataFrame.
| Parameters | Type | Description |
|---|---|---|
| path | str or sym | Glob pattern to expand (e.g., "*.txt", "data/*.csv") |
Example:
.os.setenv
Sets an environment variable.
| Parameters | Type | Description |
|---|---|---|
| name | str or sym | Environment variable name |
| value | str or sym | Environment variable value |
Example:
.os.seed
Sets the global random seed for reproducible random number generation.
| Parameters | Type | Description |
|---|---|---|
| seed | i64 | Random seed value |
Example:
.os.system
Executes a system command and returns its output.
| Parameters | Type | Description |
|---|---|---|
| command | str or sym | System command to execute |
Example:
.os.getenv
Retrieves the value of an environment variable.
| Parameters | Type | Description |
|---|---|---|
| name | str or sym | Environment variable name |
Example:
.os.mem
Retrieves the memory usage of the current process and the system available memory.
| Parameters | Type | Description |
|---|---|---|
| None | None | None |
Example:
.os.pid
Retrieves the process ID of the current process.
| Parameters | Type | Description |
|---|---|---|
| None | None | None |
.os.version
Retrieves the version of the current process.
| Parameters | Type | Description |
|---|---|---|
| None | None | None |
.os.syntax
Retrieves the syntax type of the current process.
| Parameters | Type | Description |
|---|---|---|
| None | None | None |