1. Resources
  2. /
  3. Plugins
  4. /
  5. custom-checkout-buildkite-plugin

Custom Checkout Buildkite Plugin

A Buildkite plugin for customizing repository checkouts in your pipeline. This plugin allows you to:

  • Skip the default repository checkout
  • Check out multiple repositories
  • Configure custom checkout paths

Features

  • 🚫 Skip default checkout
  • 📁 Custom checkout paths
  • 🔑 SSH key support
  • 📦 Multiple repository support

Configuration

Basic Configuration

steps:
  - label: "Skip checkout"
    command: 'echo "Skipping checkout"'
    plugins:
      - custom-checkout#v1.4.1:
          skip_checkout: true

Advanced Configuration

steps:
  - label: "Custom repository checkout"
    command: "buildkite-agent pipeline upload"
    plugins:
      - custom-checkout#v1.4.1:
          skip_checkout: true
          repos:
            - url: "https://github.com/org/repo.git"
              ref: "main"

Configuration Options

Plugin Options

OptionRequiredDefaultDescription
skip_checkoutfalsefalseSkip the default repository checkout
reposfalse[]List of repositories to check out
delete_checkoutfalsefalseDelete checkout directory after build
checkout_pathfalse$BUILDKITE_BUILD_CHECKOUT_PATHCustom checkout path

Repository Options

Each repository in the repos list can have the following options:

OptionRequiredDefaultDescription
urltrueRepository Git URL
mirror_urlfalseOptional mirror URL for faster/local clone
reffalseBranch, tag, or commit to checkout
clone_flagsfalse["-v"]Additional flags for git clone
checkout_pathfalseCustom directory path for this repository

Examples

Skip Default Checkout

steps:
  - label: "Skip checkout"
    command: 'echo "Skipping checkout"'
    plugins:
      - custom-checkout#v1.4.1:
          skip_checkout: true

Custom Repository Checkout

steps:
  - label: "Custom checkout"
    command: "buildkite-agent pipeline upload"
    plugins:
      - custom-checkout#v1.4.1:
          skip_checkout: true
          repos:
            - url: "https://github.com/org/repo.git"

Multiple Repositories

steps:
  - label: "Multiple repos"
    command: "./script.sh"
    plugins:
      - custom-checkout#v1.4.1:
          skip_checkout: true
          repos:
            - url: "https://github.com/org/repo1.git"
              ref: "main"
            - url: "https://github.com/org/repo2.git"
              ref: "dev"

Custom Checkout Paths

steps:
  - label: "Custom paths"
    command: "./script.sh"
    plugins:
      - custom-checkout#v1.4.1:
          skip_checkout: true
          repos:
            - url: "https://github.com/org/repo1.git"
              ref: "main"
              checkout_path: "/tmp/repo1"
            - url: "https://github.com/org/repo2.git"
              ref: "dev"
              checkout_path: "repo2"

Clone with Mirror URL

steps:
  - label: "Checkout with mirror"
    command: "buildkite-agent pipeline upload"
    plugins:
      - custom-checkout#v1.4.1:
          skip_checkout: true
          repos:
            - url: "https://github.com/org/repo.git"
              mirror_url: "https://git-mirror.local/org/repo.git"
              ref: "main"

Compatibility

Elastic StackAgent Stack K8sHosted (Mac)Hosted (Linux)Notes
n/a
  • ✅ Fully supported (all combinations of attributes have been tested to pass)
  • ⚠️ Partially supported (some combinations cause errors/issues)
  • ❌ Not supported

Testing

docker-compose run --rm tests

Contributing

  1. Fork the repository
  2. Create your feature branch
  3. Commit your changes
  4. Push to the branch
  5. Create a Pull Request

📜 License

The package is available as open source under the terms of the MIT License.

The plugins listed on this webpage are provided for informational purposes only. They have not undergone any formal security review or assessment. While we strive to provide useful resources, we cannot guarantee the safety, reliability, or integrity of these plugins. Users are strongly advised to conduct their own security evaluations before downloading, installing, or using any plugin. By using these plugins, you acknowledge and accept any risks associated with their use. We disclaim any liability for any harm or damages arising from the use of the plugins listed.

Start turning complexity into an advantage

Create an account to get started with a 30-day free trial. No credit card required.

Buildkite Pipelines

Platform

  1. Pipelines
  2. Public pipelines
  3. Test Engine
  4. Package Registries
  5. Mobile Delivery Cloud
  6. Pricing

Hosting options

  1. Self-hosted agents
  2. Mac hosted agents
  3. Linux hosted agents

Resources

  1. Docs
  2. Blog
  3. Changelog
  4. Example pipelines
  5. Plugins
  6. Webinars
  7. Case studies
  8. Events
  9. Migration Services
  10. Comparisons

Company

  1. About
  2. Careers
  3. Press
  4. Security
  5. Brand assets
  6. Contact

Solutions

  1. Replace Jenkins
  2. Workflows for AI/ML
  3. Testing at scale
  4. Monorepo mojo
  5. Bazel orchestration

Legal

  1. Terms of Service
  2. Acceptable Use Policy
  3. Privacy Policy
  4. Subprocessors
  5. Service Level Agreement

Support

  1. System status
  2. Forum
© Buildkite Pty Ltd 2025