Git-related Modules

git-auth

The module provides the basics for working with a git repository.

git.checkout.forgeType

The forge type according to Hercules CI.

Valid values include "github" and "gitlab", or you could forward this from herculesCI.repo.forgeType (flake-parts) or the metadata passed to the herculesCI function: primaryRepo.forgeType.

Type: string

Example: primaryRepo.forgeType

Declared by:

git.checkout.remote.url

The git remote URL. Currently only http/https URLs are supported.

The current repo URL is available in herculesCI.repo.remoteHttpUrl or the metadata passed to the herculesCI function: primaryRepo.remoteHttpUrl.

Type: string

Example: primaryRepo.remoteHttpUrl

Declared by:

git.checkout.tokenSecret

Name of the secret that contains the git token.

Type: string

Default: "token"

Declared by:

git.checkout.user

User name for authentication with the git remote.

Type: string

Default: "git"

Declared by:

git-update

A module that facilitates the updating of a git repository.

git.update.branch

Branch name to pull from and push any changes to.

Type: string

Declared by:

git.update.pullRequest.enable

Whether to create a pull request to merge the updated branch into the default branch.

Type: boolean

Default: true

Declared by:

git.update.pullRequest.autoMergeMethod

Whether to enable auto-merge on new pull requests, and how to merge it.

This requires GitHub branch protection to be configured for the repository.

Type: one of <null>, “merge”, “rebase”, “squash”

Default: null

Declared by:

git.update.pullRequest.body

The body, or description, of the pull request.

A more detailed body can be achieved by making git.update.script set the body contents in the HCI_GIT_UPDATE_PR_BODY environment variable.

Type: string

Declared by:

git.update.pullRequest.title

The title to use for the pull request.

A more detailed title can be achieved by making git.update.script set the title in the HCI_GIT_UPDATE_PR_TITLE environment variable.

Type: string

Declared by:

git.update.script

Bash statements that make changes to the checkout.

The working directory is the root of the checkout.

Type: strings concatenated with “\n”

Declared by:

See also