MCPcopy Index your code
hub / github.com/continuedev/continue / getCurrentSession

Method getCurrentSession

extensions/cli/src/session.ts:93–109  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

91 }
92
93 getCurrentSession(): Session {
94 if (!this.currentSession) {
95 // Use test session ID for testing consistency
96 const sessionId = process.env.CONTINUE_CLI_TEST_SESSION_ID
97 ? process.env.CONTINUE_CLI_TEST_SESSION_ID
98 : uuidv4();
99
100 this.currentSession = {
101 sessionId,
102 title: DEFAULT_SESSION_TITLE,
103 workspaceDirectory: process.cwd(),
104 history: [],
105 usage: { ...this.sessionUsage },
106 };
107 }
108 return this.currentSession;
109 }
110
111 setSession(session: Session): void {
112 this.currentSession = session;

Callers 6

updateHistoryMethod · 0.95
updateTitleMethod · 0.95
getSessionIdMethod · 0.95
trackUsageMethod · 0.95
saveSessionFunction · 0.80
getCurrentSessionFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected