Skip to main content

commit

plugin.git.commit(message: string): Promise<GitCommitResponse>

Commits the staged changes in the local repository with the given commit message.

Parameters

ParameterTypeRequiredDescription
messagestringYesThe commit message to use for the commit.

Returns

Promise<GitCommitResponse> — A promise that resolves with the response from the commit event.

Example

import plugin from '@codebolt/plugin-sdk';

const result = await plugin.git.commit('message');
console.log(result);