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
olt setup # full system setup: OLS detection, install, symlinks
40
+
olt init # create olt.toml in a project directory
42
41
```
43
42
44
-
Detects OLS, creates `olt.toml` with a rule profile, and installs binaries to `~/.local/bin/`.
43
+
`olt init` detects if setup has been run and offers to run it first if needed.
45
44
46
45
---
47
46
@@ -51,12 +50,14 @@ Detects OLS, creates `olt.toml` with a rule profile, and installs binaries to `~
51
50
olt src/ # lint a directory (recursive)
52
51
olt file.odin # lint a single file
53
52
olt src/ --fix # apply safe auto-fixes in-place
54
-
olt src/ --propose # show proposed fixes as a diff
55
53
olt src/ --format json # machine-readable output (json or sarif)
56
54
olt src/ --rule C001,C201 # run specific rules only
57
55
olt src/ --tier correctness # run only correctness-tier rules
58
56
olt --explain C001 # detailed rule documentation
59
57
olt --list-rules # show all available rules
58
+
59
+
olt mcp # start MCP server (AI agent interface)
60
+
olt lsp # start LSP proxy (editor interface)
60
61
```
61
62
62
63
### Exit codes
@@ -112,7 +113,7 @@ Enable in `olt.toml`:
112
113
113
114
## Configuration — olt.toml
114
115
115
-
Place`olt.toml` at your project root (or run `olt --init` to generate one):
116
+
Run`olt init` in your project directory to generate one, or create it manually:
116
117
117
118
```toml
118
119
[domains]
@@ -128,7 +129,7 @@ c020_min_length = 3
128
129
c020_allowed = "i,j,k,x,y,z,n,ok,err,db,id"
129
130
130
131
[tools]
131
-
ols_path = "/usr/local/bin/ols"# path to OLS (if not in PATH)
132
+
ols_path = "/usr/local/bin/ols_lsp"# path to OLS (if not in PATH)
132
133
```
133
134
134
135
### Inline suppression
@@ -143,45 +144,47 @@ Legacy alias `// odin-lint:ignore` is also accepted.
143
144
144
145
---
145
146
146
-
## Editor integration — olt-lsp
147
+
## Editor integration
148
+
149
+
`olt lsp` is an LSP proxy: your editor talks to it as the single Odin language server.
150
+
It forwards everything to vanilla [OLS](https://github.com/DanielGavin/ols) (completions, hover, go-to-definition) and injects olt diagnostics into the diagnostic stream.
147
151
148
-
`olt-lsp` is an LSP proxy: your editor talks to it as the single Odin language server.
149
-
It forwards everything to vanilla [OLS](https://github.com/DanielGavin/ols) (completions, hover, go-to-definition) and injects olt lint diagnostics into the diagnostic stream.
152
+
After `olt setup`, an `ols` symlink is created pointing to `olt`. Point your editor at that symlink — no other changes needed.
|`lint_fix`|Apply fixes and return a before/after diff|
198
+
|`lint_fix`|Return proposed fixes as JSON|
196
199
|`lint_workspace`| Batch-lint a directory |
197
200
|`list_rules`| Return the full rule catalog as JSON |
198
201
|`run_odin_check`| Run `odin check` and return compiler diagnostics |
199
-
|`codegraph_search`| Search the code knowledge graph by symbol name |
200
-
|`codegraph_context`| Get relevant context for a task |
201
-
|`codegraph_callers`| Find what calls a function |
202
-
|`codegraph_callees`| Find what a function calls |
203
-
|`codegraph_impact`| See what's affected by changing a symbol |
204
-
|`codegraph_node`| Get source and metadata for a symbol |
202
+
|`get_symbol`| Look up a symbol in the code graph |
203
+
|`export_symbols`| Build the code knowledge graph |
204
+
|`get_dna_context`| Callers, callees, memory role for a proc |
205
+
|`get_impact_radius`| Transitive impact of changing a symbol |
206
+
|`get_callers` / `get_callees`| Direct call graph neighbours |
207
+
|`search_symbols`| Full-text symbol search |
208
+
|`rename_symbol`| Generate rename patches across the project |
205
209
206
210
### Code knowledge graph
207
211
@@ -211,46 +215,47 @@ Build a semantic graph of your project for deeper analysis:
211
215
olt src/ --export-symbols
212
216
```
213
217
214
-
This writes a SQLite database to `.codegraph/olt_graph.db` and enables:
215
-
- C202 switch exhaustiveness checking
216
-
-`codegraph_*` MCP tools for AI-assisted refactoring
217
-
- C012 T3 graph-backed ownership analysis
218
+
This writes a SQLite database to `.codegraph/olt_graph.db` and enables C202 switch exhaustiveness checking and all `get_*` / `search_symbols` MCP tools.
0 commit comments