You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Each `run` invocation is fully independent. FineCode starts a dedicated API server subprocess for the duration of the command, then shuts it down on exit. This is the default behavior.
19
+
20
+
```bash
21
+
python -m finecode run lint
22
+
```
23
+
24
+
Use this in CI/CD pipelines or any context where you don't want persistent background processes. Results from one action can be saved to the file cache and referenced by a later action via `--map-payload-fields` (see the `run` reference below).
25
+
26
+
### Persistent server
27
+
28
+
A long-lived API server holds warm state — loaded configuration, started runners — across multiple `run` calls. Use `--shared-server` to connect to a running shared instance instead of starting a dedicated one.
29
+
30
+
```bash
31
+
# Connect to the shared server (start it first if needed):
32
+
python -m finecode run --shared-server lint
33
+
python -m finecode run --shared-server format
34
+
```
35
+
36
+
This mode is used automatically by the LSP and MCP integrations. It gives faster repeated runs because configuration loading and runner startup are amortized across calls.
37
+
38
+
The server waits 30 seconds after the last client disconnects before shutting down (configurable via `--disconnect-timeout` on `start-api-server`).
|`--no-save-results`| Do not write action results to the cache directory |
@@ -155,14 +186,15 @@ Typically started automatically by MCP-compatible clients (for example, Claude C
155
186
156
187
## `start-api-server`
157
188
158
-
Start the FineCode API server standalone (TCP JSON-RPC), listen for client connections. Auto-stops when the last client disconnects.
189
+
Start the FineCode API server standalone (TCP JSON-RPC), listen for client connections. Shuts down after the last client disconnects and the disconnect timeout expires.
0 commit comments