Contributing to BLT


Acquia will end support for BLT on December 31, 2024. For more information on how to replace your BLT implementation with updated functionality, see You don’t need BLT on Acquia Cloud.

Before you create an issue or pull request, Acquia recommends reading and taking the time to understand the following guide. Submitted issues not based on these guidelines may be closed.

BLT feature requests, bugs, Support requests, and milestones are tracked with the BLT GitHub issue queue.

Note the branch statuses documented on the GitHub page:

  • Pull requests for enhancements will be accepted only for the active development branch (main).

  • Pull requests for bug fixes will be accepted only for supported versions.

General guidelines

Note the following guidelines when submitting issues or pull requests:

  • Issues filed directly with the BLT project aren’t subject to a service-level agreement (SLA).

  • BLT is distributed under the GPLv2 license; all documentation, code, and guidance is provided without warranty.

  • The project maintainers are under no obligation to respond to support requests, feature requests, or pull requests.

  • If more information is requested and no reply is received within a week, issues may be closed.

Newly filed issues will be reviewed by a BLT maintainer and added to the backlog milestone if accepted.

BLT does not publish timelines or road maps to reflect when individual issues will be addressed. If you would like to request prioritization of a specific ticket, complete the following tasks:

  • Submit product feedback through your Technical Account Manager or create a Support ticket on your Cloud subscription.

  • Vote for the relevant issue by adding a +1 reaction.

  • Submit a pull request, which will receive priority review.

Submitting issues

Before submitting an issue, be sure to search for existing issues (including closed issues) matching your issue. Duplicate issues will be closed.

Use caution when selecting your issue type, and if you aren’t sure of the issue type, create a Support ticket.

  • Feature request: A request for a specific enhancement for BLT. A feature request is distinct from a bug report because it indicates a missing feature for BLT instead of a literal error with BLT. Feature requests are distinct from Support requests because they’re specific and atomic requests for new BLT features, instead of a general request for help or guidance.

  • Bug report: A defined instance of BLT not behaving as expected. A bug report is distinct from a feature request because it represents a mismatch between what BLT does and what BLT claims to do. A bug report is distinct from a support request by including specific steps to reproduce the problem (ideally starting from a fresh installation of BLT) and justifying why the instance is a problem with BLT rather than with an underlying tool, such as Composer or Drush.

  • Support request: A request for help or guidance. Use the issue type if you aren’t sure how to do something or can’t find a solution to a problem that may or may not be a bug. Before filing a Support request, review BLT support for solutions to common problems and general troubleshooting techniques.

    If you have an Acquia subscription, create a Support ticket instead of a BLT issue to receive support subject to your SLA.

After selecting your issue type, be sure to complete the entire issue template.

Submitting pull requests

Note the branch statuses documented on the GitHub page:

  • Pull requests for enhancements will only be accepted for the active development branch (main).

  • Pull requests for bug fixes will only be accepted for supported versions.

  • When submitting a pull request for a bug fix or enhancement applying to several branches, submit only a single pull request to the latest development branch for review. A maintainer will backport the fix if appropriate.

Pull requests must also adhere to the following guidelines:

  • Pull requests must be atomic and targeted at a single issue rather than broad scope.

  • Pull requests must contain clear testing steps and justification, and all other information required by the pull request template.

  • Pull requests must pass automated tests before they will be reviewed. Acquia recommends running the tests locally before submitting.

  • Pull requests must meet Drupal coding standards and best practices as defined by the project maintainers.

Developing BLT locally

Developing and testing changes to BLT requires linking BLT into a functioning Drupal codebase (referred to as the “test fixture”) and then running tests using PHPUnit. BLT is fully integrated with Acquia ORCA, which accelerates the process of creating the test fixture and running automated tests.

Creating the test fixture with ORCA

Acquia recommends using ORCA to create the test fixture, since BLT’s continuous integration also uses ORCA and the ORCA fixture does not rely on dependencies such as MySQL or Vagrant. Follow ORCA’s getting started instructions to clone and set up ORCA locally.

From the ORCA installation directory, run the following command to create the fixture in a sibling ../orca-build directory:

./bin/orca fixture:init -f --sut=acquia/blt --sut-only --core='~9' --dev

See ORCA’s documentation or inline command help for details on how to change the fixture location or configuration.

Creating the test fixture without ORCA

You can link BLT into an existing codebase without using ORCA. Use the command blt:dev:link-composer to link a local version of BLT into your codebase using a Composer path repository. This command also configures Vagrant to use your development version of BLT.

Due to Vagrant restrictions for handling symlinks, Vagrant supports two types of directory structures:

The first is to place BLT directly next to the project you are testing. For instance:

  • BLT is located at ~/blt

  • Your BLT test project is located at ~/blted

  • From your project (~/blted), run the following command:

    blt blt:dev:link-composer --blt-path=../blt

The second supported structure is to have BLT as a sibling once removed from your test project, for example:

  • BLT is located at ~/packages/blt

  • Your BLT test project is located at ~/sites/blted

  • From your project (~/blted), run the following command with no arguments (this is the default structure):

    blt blt:dev:link-composer

Your blted project will now have a Composer dependency on your local clone of BLT through a symlink. You can make changes to files in blt and see them instantly reflected in blted/vendor/acquia/blt.

Running automated tests

Acquia recommends using ORCA to run automated tests. You must set the ORCA_FIXTURE_DIR environment variable to inform BLT of the fixture location. For example, if your fixture directory is /home/me/packages/orca-build, you could run automated tests with the following command:

ORCA_FIXTURE_DIR=/home/me/packages/orca-build ./bin/orca qa:automated-tests --sut=acquia/blt --sut-only

ORCA uses sqlite databases and the Drush built-in web server for testing, so there is no dependency on an external database or web server.

You can also run PHPUnit directly from the BLT directory, but this is not supported or recommended. If you don’t use ORCA, you are responsible for configuring PHPUnit and all necessary dependencies (such as a database, web server, and related credentials in the Drupal codebase).