GitLab API

GitlabTool

Actions905

Overview

This node operation performs a cherry-pick of a commit in a GitLab project repository. It is useful for selectively applying changes from one commit to another branch without merging the entire branch. For example, developers can use this to apply bug fixes or features from a specific commit to a release branch.

Use Case Examples

  1. Cherry-pick a commit identified by its SHA from the main branch to a feature branch in a GitLab project.
  2. Apply a specific commit from a tag to the current working branch to quickly patch an issue.

Properties

Name Meaning
Skip Authentication Option to skip authentication for the request.
Authentication Type of authentication used, defaulting to GitLab API key.
baseUrl Base URL of the GitLab instance, default is https://gitlab.com.
Method HTTP method to use for the request, default is GET.
Path Parameters Parameters for the API path including project ID and commit SHA to cherry-pick.

Output

JSON

  • id - The ID or URL-encoded path of the project.
  • sha - The commit SHA or reference to be cherry-picked.
  • cherryPickResult - Result of the cherry-pick operation, typically including commit details or status.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the project ID and commit SHA are correct and accessible with the provided credentials.
  • Authentication errors may occur if the API key is missing or invalid; verify the API key and permissions.
  • Cherry-pick conflicts or failures may happen if the commit cannot be applied cleanly; check the GitLab project repository state and commit history.

Links

Discussion