import { BaseService } from '../infrastructure'; import { RequestOptions } from '../infrastructure/RequestHelper'; export interface CommitAction { /** The action to perform */ action: 'create' | 'delete' | 'move' | 'update'; /** Full path to the file. Ex. lib/class.rb */ file_path: string; /** Original full path to the file being moved.Ex.lib / class1.rb */ previous_path?: string; /** File content, required for all except delete. Optional for move */ content?: string; /** text or base64. text is default. */ encoding?: string; /** Last known file commit id. Will be only considered in update, move and delete actions. */ last_commit_id?: string; } declare class Commits extends BaseService { all(projectId: ProjectId, options: RequestOptions): Promise; cherryPick(projectId: ProjectId, sha: string, branch: string): Promise; comments(projectId: ProjectId, sha: string): Promise; create(projectId: ProjectId, branch: string, message: string, actions: CommitAction[], options: RequestOptions): Promise; createComment(projectId: ProjectId, sha: string, note: string, options: RequestOptions): Promise; diff(projectId: ProjectId, sha: string): Promise; editStatus(projectId: ProjectId, sha: string, options: RequestOptions): Promise; references(projectId: ProjectId, sha: string): Promise; show(projectId: ProjectId, sha: string, options: RequestOptions): Promise; status(projectId: ProjectId, sha: string, options: RequestOptions): Promise; } export default Commits;