1. Resources
  2. /
  3. Plugins
  4. /
  5. pr-commenter-buildkite-plugin

PR Commenter Plugin Build status

A Buildkite plugin written in Go that enables commenting on pull requests that builds are triggered from.

The plugin uses the /issues endpoint as that doesn’t require a commit SHA or file name in order to post the comment; this comment will post to the conversation tab and won’t be associated with any file changes.

The plugin has been tested and built using go 1.20.3, so it is not guaranteed to work on versions <1.20.3.

The plugin binary will get built in the step and output as a pre-exit hook. This ensures that it runs as the last command on the step and is able to get the exit code of the step that it runs on (necessary for the default message).

The use of this plugin requires that clusters are being used and that the secret is available on that cluster, else the plugin will error.

👩‍💻 Usage

Add the following to your pipeline.yml:

    steps:
        command: echo "cool plugin!"
        plugins:
            - pr-commenter#v0.0.1:
                message: "LGTM!"
                secret-name: GITHUB_TOKEN

📒 Options

secret-name (optional, string)

The environment variable that contains the value of the GitHub API token. If not set, the plugin will try to get the URL from the default configuration.

Default: GITHUB_TOKEN

message (optional, string)

The message which should be posted to the PR. This can be a dynamic value, such as $BUILDKITE_COMMAND

Default: [https://buildkite.com/mock-org/cool-pipeline/builds/420#step-id](https://buildkite.com/mock-org/cool-pipeline/builds/420#step-id) exited with code 0

🛠️ Development

Running the tests

The tests are written using Go’s built-in testing package.

Tests can be run using:

go test -v ./...

💪 Contributing

We welcome all contributions to improve this plugin! To contribute, please follow these guidelines:

  • Fork the repository
  • Make your changes and ensure that the tests pass.
  • Write clear and concise commit messages.
  • Submit a pull request.

By contributing, you agree to license your contributions under the LICENSE file of this repository.

License

MIT (see 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. Pipeline templates
  3. Public pipelines
  4. Test Engine
  5. Package Registries
  6. Mobile Delivery Cloud
  7. Pricing

Hosting options

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

Resources

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

Company

  1. About
  2. Careers
  3. Press
  4. Brand assets
  5. 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