Line

ui/client/features/git-session/services/GitSessionApi

Reading and configuring the commit-on-save session.

Cockpit client (features), v0.9. Source: ui/client/features/git-session/services/GitSessionApi.ts.

Functions#

fetchGitSession()#

fetchGitSession(): Promise<GitSessionStatus>

Defined in: ui/client/features/git-session/services/GitSessionApi.ts:8

#365: with no project open the server answers 409 { ok: false, code: 'NO_PROJECT' }. That is "no session", not a status, so it is thrown (the hook turns it into a failed load) instead of being passed on as one.

Returns#

Promise<GitSessionStatus>


saveCommitConfig()#

saveCommitConfig(patch): Promise<{ config?: CommitConfig; error?: string; ok: boolean; }>

Defined in: ui/client/features/git-session/services/GitSessionApi.ts:14

Parameters#

patch

Partial<CommitConfig>

Returns#

Promise<{ config?: CommitConfig; error?: string; ok: boolean; }>