fluffos/docs/cli/driver.md

40 lines
2 KiB
Markdown
Raw Permalink Normal View History

2024-01-01 13:09:00 -08:00
---
title: cli / driver
---
# cli / driver
`driver` is the main binary produced from FluffOS Project.
## Usage
```bash
./driver [flags] config_file
```
## Flags
| Flag | Description |
|--------------------------|---------------------------------------------------------------------------------------------------------------------------|
| `-f<flag>` | After initialization, before opening network connections, driver will call `void flag(string)` function on master object. |
| `-d<category>` | Enable debug logging, this flag can occur multiple times. This is same as calling `set_debug_level()` EFUN. |
| `--tracing <trace_file>` | Enable LPC tracing |
Generate driver config docs and a starter config from rc.cc tables (#1206) * Generate driver config docs and a starter config from rc.cc tables Make the runtime-config option tables in rc.cc the single source of truth for documentation, so the docs can no longer drift from the driver. - rc.cc: add `category`/`description` fields to the int-option table (INT_FLAGS) and introduce a STR_FLAGS table for the simple string options, parsing them directly from the table in read_config(). - docs/gen_config_docs.py: generate docs/driver/config.md from those tables (resolving expression/macro defaults). `--check` mode fails if the committed doc is stale. - .github/workflows/config-docs.yml: run the generator with --check on changes to rc.cc/options_internal.h/the generator/the doc. - docs/driver/config.md: regenerated; now covers all recognized options accurately (previously ~half, with some stale/nonexistent entries). - driver --generate-config: emit a complete, bootable starter config to stdout (ints at defaults, required paths as placeholders, websocket/ TLS/external bits commented out). Comment lines are wrapped to stay under the parser's per-line limit. - Config.example: add the 9 previously-missing options and fix the "call_out(0) next level" -> "nest level" typo. - CLAUDE.md / docs/CLAUDE.md / docs/cli/driver.md: document the source of truth, the regeneration workflow, and the new flag. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * Config.example: keep only valid options Remove options the driver doesn't actually use: - obsolete (driver warns to delete): `binary directory`, `swap file` - unrecognized / silently ignored: `apply cache bits`, `maximum users`, `compiler stack size` Relocate `evaluator stack size` (a valid limit) up with the other limits and drop the now-empty "not currently used or implemented" section, and remove the `binary directory` mention from the header note. Verified: the cleaned sample boots a mudlib to "Initializations complete" with no obsolete-line warnings. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 13:07:06 -04:00
| `--generate-config` | Print a starter config file (all options, with defaults and comments) to stdout and exit. Redirect to a file to use it. |
2024-01-01 13:09:00 -08:00
## Debug logging Categories
| Category | Description |
|-----------------|--------------------------------------|
| `call_out` | Callouts |
| `d_flag` | Legacy combination of various events |
| `connections` | external connections |
| `mapping` | Mapping operations |
| `sockets` | LPC Sockets related logs |
| `comp_func_tab` | Compilation |
| `LPC` | LPC execution |
| `LPC_line` | LPC execution |
| `event` | Events |
| `dns` | DNS resolution logs |
| `file` | Filesystem operations |
| `add_action` | add_action packages related logs |
| `telnet` | Telnet protocol |
| `websocket` | Websocket protocol |