Create destructive repository commit
create_destructive_commitCreate a GitLab commit that deletes files or force-updates a branch. Requires a reviewed start_sha; delete actions also need last_commit_id to prevent overwriting concurrent changes.
Instructions
Create one GitLab commit that can delete files or force a branch update. For ordinary updates, the branch tip must match start_sha before the commit is submitted; forced updates use start_sha as GitLab's explicit replacement parent. Delete actions also require last_commit_id.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| force | No | Allow GitLab to force the branch update. Use only after explicitly reviewing the target ref. | |
| branch | Yes | ||
| actions | Yes | ||
| project | Yes | GitLab project ID or full path such as group/project. | |
| start_sha | Yes | Reviewed commit SHA from which GitLab must apply this destructive change. | |
| author_name | No | ||
| author_email | No | ||
| commit_message | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes | Created destructive GitLab commit, including its commit ID, SHA, and affected file actions when GitLab returns them. |