mirror of
https://github.com/chriswritescode-dev/opencode-manager.git
synced 2026-12-06 12:54:20 +01:00
feat(servers): switch the sidebar listing between local and linked servers
The Servers section becomes a Local/server switcher shared by the desktop sidebar, collapsed rail and mobile repo sheet. Selecting a linked server lists its projects and sessions with the same navigation as local repos, and a remote project page mirrors the local repo page.
This commit is contained in:
1 parent
cb9b7645e6
commit
36b8c1b200
29 files changed
+2080
-201
No files matched your search
@@ -290,6 +290,17 @@ export function serverActivityFromIndex(
|
||||
return running ? 'running' : null
|
||||
}
|
||||
|
||||
/**
|
||||
* A linked server project's activity from a prebuilt server index, keyed by server and directory.
|
||||
*/
|
||||
export function projectActivityFromIndex(
|
||||
serverId: string,
|
||||
directory: string,
|
||||
index: ReadonlyMap<string, 'needs-input' | 'running'>,
|
||||
): 'needs-input' | 'running' | null {
|
||||
return index.get(serverIndexKey(serverId, directory)) ?? null
|
||||
}
|
||||
|
||||
/**
|
||||
* The repo's activity from a prebuilt index, checking each of its own paths and the directories of
|
||||
* the worktrees it owns. Needs-input outranks running.
|
||||
|
||||
Reference in new issue
Block a user