Rename the on-disk directory tokens to Tokens, matching its
PascalCase siblings (Projects, HookPacks). FileTokenStore
now names files <service> or <service>.<account>; the
.token suffix and luma.llm. / re.frida.Luma prefixes are
gone. Existing entries become orphaned and users will be
prompted to enter API keys and re-auth GitHub on next run.
Replace the auto-reopen-last-document flow with a welcome
screen that lets the user start a new project, open one
from disk, or — after signing in with GitHub — pick from
a list of labs they're a member of. The list is fetched
via a new transient portal connection that issues
.list /labs and disconnects.
Token persistence on macOS now goes through a file under
~/Library/Application Support/re.frida.Luma/tokens/ to
avoid the per-launch keychain prompt that dev-signed
builds suffer; iOS keeps using the keychain. GitHubAuth
caches the load Task so concurrent waiters share one
keychain access, and now flips state to .authenticated
when a persisted token is loaded so the welcome view
shows the labs section right away. requestToken awaits
the load before falling through to a fresh sign-in.
Engine accepts an injected GitHubAuth so the welcome
window and any subsequently-opened document share one
auth instance — no second sign-in prompt when crossing
from welcome to a document.
Workspace is now a thin host adapter. Engine owns sessions and
notebook entries (via store observation), GitHub auth + OAuth
device flow, hook-pack discovery, address annotations and address
actions, the disassembler cache, and all instrument lifecycle.
EventLog is @Observable so SwiftUI tracks it directly; the host
no longer mirrors event arrays or version counters.
R2 (live disassembly + trace inspection) lives entirely in
LumaCore as concrete Disassembler / TraceDisassembler classes
returning portable StyledText spans. ProcessNodeViewModel and
InstrumentRuntime are gone; views read engine.processNodes /
node.instruments / engine.descriptor(for:) directly.
Reorganize Luma/Models/ — instrument UI dispatch lives under
Luma/Instruments/, Monaco editor glue under Luma/Editor/, and the
remaining UI types sit at the top of Luma/.
Lay the groundwork for a GTK/Adwaita frontend by extracting
shared infrastructure into a LumaCore Swift package. Agent
sources and LumaBundleCompiler move to top-level locations
so both the Xcode project and SPM can reference them.
New structure:
- Package.swift: root manifest with LumaCore lib + compiler
- Sources/LumaCore/: engine, persistence, models, and
platform-abstracted token store
- Sources/LumaBundleCompiler/: moved from LumaBundleCompiler/
- Agent/: moved from Luma/Agent/
- LumaGtk/: skeleton GTK app package