Skip to content
Fallow home
All docs pages

fallow ci-template: print or vendor the GitLab CI template

Print the fallow GitLab CI template, or vendor it with its helper scripts into your repository so pipelines run without a download from GitHub.

fallow ci-template prints a CI integration template, or writes it into your repository with its helper scripts. It has one subcommand, gitlab.

fallow ci-template gitlab                 # print the template on stdout
fallow ci-template gitlab --vendor        # write the template and the helper scripts
fallow ci-template gitlab --vendor ci-dir # write them below another directory

The template is the one that the bundled fallow version ships. For the setup and the template variables, see GitLab CI.

ci-template gitlab

FlagDescription
--vendor [<DIR>]Write the files below DIR, and do not print the template. Without DIR, the command writes to the current directory.
--forceOverwrite existing files that are different from the bundled template.

Without --vendor, the command prints gitlab-ci.yml on stdout.

With --vendor, the command writes these files:

  • ci/gitlab-ci.yml
  • ci/scripts/comment.sh
  • ci/scripts/review.sh
  • ci/scripts/gitlab_common.sh

The vendored template uses the local scripts. A pipeline then downloads nothing from raw.githubusercontent.com for MR comments and inline review. Commit the files, and include the local template:

include:
  - local: 'ci/gitlab-ci.yml'

fallow:
  extends: .fallow

A file that is equal to the bundled version is not a conflict, so you can run the command again. When a file exists with other content, the command stops with exit code 2 and names the file. Pass --force to overwrite it. Run the command again after you update fallow, so that the vendored files match the new version.

Options

The command accepts the global flags. They do not change the template.

See also