turbo-editors/turbo-corepublic Fork 0
fe2328870c726beecc5bc34fd3d05acba9fec94f
Commits
Clone
git clone https://git.rickub.com/turbo-editors/turbo-core.git
git clone ssh://git@rickub.com/turbo-editors/turbo-core.git

Host key fingerprint (ed25519): SHA256:iycHnxEyq0Q7uyVpB7JlznP0G7JrTPXLYRcAU5CSLhc — verify it before your first connect.

packages.md · 61 lines · 3.8 KBmarkdown Blame HistoryRaw
🛟 Updated. 28d5985 k33g yesterday1# Reference: packages
2
3> Neutral, exhaustive description of what turbo-core holds.
4
📦 Turbo Core — files rewritten outside reload into their windows; the agent window wraps what you type and keeps a long paste aside as a token (#28); configrepo fetches a shared .turbo-<slug> from a forge URL (#25) fe23288 k33g 13h ago5Nineteen packages. Dependencies run strictly downwards; there are no cycles and no interface indirection to prevent one.
🛟 Updated. 28d5985 k33g yesterday6
7```
8app → {editor, ui, lsp, buffer, terminal, filetree, settings, snippets, tools, syntax, theme, profile, version}
9 editor → {buffer, syntax, ui, theme}
10 terminal → {ui, theme, tcell, golang.org/x/sys}
11 filetree → {ui, theme, tcell}
12 snippets → {toml, projectfile, profile}
13 settings → {toml, projectfile, profile}
14 tools → {toml, projectfile, profile}
📦 Turbo Core — files rewritten outside reload into their windows; the agent window wraps what you type and keeps a long paste aside as a token (#28); configrepo fetches a shared .turbo-<slug> from a forge URL (#25) fe23288 k33g 13h ago15 configrepo → {projectfile, profile} ← runs the git command
🛟 Updated. 28d5985 k33g yesterday16 syntax → theme
17 ui → theme
18 theme → {profile-free; takes a directory}, tcell, toml
19 lsp → profile
20```
21
22| Package | What it holds | Depends on |
23| --- | --- | --- |
24| `profile` | The editor's identity: name, slug, language server, starter templates, and the paths derived from them | **stdlib only** |
25| `buffer` | The text of one file: lines of runes, cursor, selection, undo, search, load and save | **stdlib only** |
26| `projectfile` | Atomic writes of the TOML files a project keeps in the editor's own directory | **stdlib only** |
📦 Turbo Core — files rewritten outside reload into their windows; the agent window wraps what you type and keeps a long paste aside as a token (#28); configrepo fetches a shared .turbo-<slug> from a forge URL (#25) fe23288 k33g 13h ago27| `configrepo` | A shared configuration directory fetched from a forge URL (rickub, GitHub, GitLab, Codeberg) by a shallow git clone, for an editor's `-load-config` | `projectfile`, `profile`, the `git` command |
🛟 Updated. 28d5985 k33g yesterday28| `version` | What build of itself a binary is: linker stamp, then Go build info | **stdlib only** |
29| `jsonrpc` | JSON-RPC 2.0 over a framed stream: calls, notifications, inbound requests answerable later | **stdlib only** |
30| `lsp` | LSP framing, the methods, and the child process | `jsonrpc`, `profile` |
31| `theme` | TOML into tcell styles; eleven embedded themes plus the user's own; two kinds of inheritance | `tcell`, `toml` |
32| `syntax` | Colouring: eight built-in languages, the registry an editor adds its own to, and the scanner toolkit | `theme` |
33| `settings` | A project's `settings.toml`: load, create, rewrite one key in place | `toml`, `projectfile`, `profile` |
34| `snippets` | Reusable text from a project's and a user's `snippets.toml`, grouped for a menu | `toml`, `projectfile`, `profile` |
35| `tools` | The commands a project runs on itself, and which menu each is in | `toml`, `projectfile`, `profile` |
36| `ui` | Turbo Vision widgets: painter, desktop, window, menu, dialog, controls, status bar | `theme`, `tcell` |
37| `editor` | The editing widget: viewport, scrolling, keys, mouse, snippet insertion | `buffer`, `syntax`, `theme`, `ui` |
38| `terminal` | A shell in a window: pseudo-terminal, VT/ANSI emulator, screen grid, the widget | `theme`, `ui`, `tcell`, `golang.org/x/sys` |
39| `filetree` | A project's files as an expandable tree, and the window showing it | `theme`, `ui`, `tcell` |
40| `acp` | A coding agent in a window: the Agent Client Protocol, the conversation, the widget | `jsonrpc`, `profile`, `projectfile`, `syntax`, `theme`, `ui`, `tcell`, `toml` |
41| `app` | Assembly: menus, dialogs, event routing, completion popup, language-server lifecycle | all of the above |
42
43## Third-party dependencies
44
45Three, and only three:
46
47| Module | Why |
48| --- | --- |
49| `github.com/gdamore/tcell/v2` | the terminal |
50| `github.com/BurntSushi/toml` | every configuration file the editor reads |
51| `golang.org/x/sys` | the pseudo-terminal ioctls on Linux and macOS; the pseudo-console, process and job-object calls on Windows |
52
53The tokeniser, the JSON-RPC client, the LSP framing and the VT/ANSI emulator are hand-written.
54
55## The diagram
56
57`docs/diagrams/packages.drawio` holds the same graph in draw.io format, checked against `go list -deps`.
58
59## See also
60
61- Why the graph is shaped this way: [architecture](../explanation/architecture.md)