forked from acquia/blt
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Resolves acquia#219: Documenting committing dependencies.
- Loading branch information
Showing
3 changed files
with
65 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# Committing Dependencies | ||
|
||
Composer's official stance is that you should not commit dependencies. | ||
|
||
However, there are sometimes extenuating circumstances that require you to commit your dependencies. In this case, you can commit your dependencies by following these steps: | ||
|
||
* Modify your project's `.gitignore` by removing the following lines: | ||
|
||
docroot/core | ||
docroot/modules/contrib | ||
docroot/themes/contrib | ||
docroot/profiles/contrib | ||
docroot/libraries | ||
drush/contrib | ||
vendor | ||
|
||
* Create a custom deploy.exclude_file and reference its location in your project.yml | ||
|
||
mkdir blt/deploy && cp vendor/acquia/blt/scripts/files/deploy-exclude.txt blt/deploy/deploy-exclude.txt | ||
deploy: | ||
exclude_file: ${repo.root}/blt/deploy/deploy_exclude.txt | ||
|
||
* Modify your custom deploy_exclude.txt file by removing the following lines: | ||
|
||
/docroot/core | ||
/docroot/libraries/contrib | ||
/docroot/modules/contrib | ||
/docroot/sites/*/files | ||
/docroot/sites/*/private | ||
/docroot/themes/contrib | ||
/drush/contrib | ||
/vendor | ||
|
||
* Set `deploy.build-dependencies` to `false` in your `project.yml` file: | ||
|
||
deploy: | ||
build-dependencies: false | ||
|
||
* Commit your changes and dependencies: | ||
|
||
git add -A | ||
git commit -m 'Committing dependencies.' | ||
|
||
Your dependencies will now be committed to your repository and copied to your deployment artifact. |