Skip to main content

commit

client.git.commit(data: GitCommitRequest): Promise<unknown>

Creates a new Git commit with the staged changes.

Commits all currently staged files with the provided commit message and optional author information.

Parameters

ParameterTypeRequiredDescription
dataGitCommitRequestYesCommit parameters including the commit message

Returns

Promise<unknown> — A promise that resolves when the commit is created

Example

import { CodeBoltClient } from '@codebolt/clientsdk';

const client = new CodeBoltClient();

const result = await client.git.commit(/* GitCommitRequest */);
console.log(result);