GitLabWrapper

GitLabWrapper

The command class that wraps GitLab related functionality for Release and Publish.

Constructor

new GitLabWrapper(token)

The wrapper class that provides an API interface for all GitLab related operations.

Source:

The wrapper class that provides an API interface for all GitLab related operations.

Parameters:
Name Type Description
token string

The GitLab Personal Access Token to be used to access the repositories

Methods

(async) createRelease(releaseData) → {null}

Given the required data, creates a release on GitLab.

Source:
Parameters:
Name Type Description
releaseData object

The data required for creating a release on GitLab

Returns:

Nothing.

Type
null

(async) fetchCommitAuthorInformation(repository, commitLog) → {object}

Given a GitLab repository, returns information about the commit author pointed to by the commitLog object.

Source:
Parameters:
Name Type Description
repository object

the GitLab repository to query for the release

commitLog string

the git commit object for which the author information needs to be fetched

Returns:

The required information about the commit author from GitLab.

Type
object

(async) fetchCommitInformation(repository, commitLog) → {object}

Given a GitLab repository, returns information about the commit pointed to by the commitLog object.

Source:
Parameters:
Name Type Description
repository object

the GitLab repository to query for the release

commitLog string

the git commit object for which commit information needs to be fetched

Returns:

The required information about the commit from GitLab.

Type
object

(async) fetchReleaseInformation(repository, releaseName) → {object}

Given a GitLab repository, returns information about the release - either the latest, or the one matching the specified release name.

Source:
Parameters:
Name Type Description
repository object

the GitLab repository to query for the release

releaseName string

the name of the release

Returns:

The required information about the release from GitLab.

Type
object

Given a GitLab repository, and a commit, returns the URL to access the commit directly.

Source:
Parameters:
Name Type Description
repository object

the GitLab repository to query for the release

commitLog object

the commit information

Returns:

The URL to access the commit on GitLab.

Type
object