Files
zmo-cli/packages/opencode/src/cli/cmd/tui/context/directory.ts
T
2025-11-26 20:11:39 -05:00

13 lines
355 B
TypeScript

import { createMemo } from "solid-js"
import { useSync } from "./sync"
import { Global } from "@/global"
export function useDirectory() {
const sync = useSync()
return createMemo(() => {
const result = process.cwd().replace(Global.Path.home, "~")
if (sync.data.vcs?.branch) return result + ":" + sync.data.vcs.branch
return result
})
}