@@ -21,7 +21,7 @@ these. Unfortunately, such tools generally require extra work for a Civi
developer environment. Civibuild works with these tools and and fills
in missing parts.
## Your First Build
## Your First Build {:#start}
!!! tip
Login as a non-`root` user who has `sudo` permission. This will ensure that new files are owned by a regular user, and (if necessary) it enables `civibuild` to restart Apache or edit `/etc/hosts`.
...
...
@@ -148,7 +148,7 @@ These aliases exactly match the demo sites deployed under civicrm.org (e.g.
If you have a working civibuild site and you'd like to upgrade CiviCRM to the latest version, follow these steps:
### Begin in the civicrm directory within your site {:#upgrade-begin}
### Begin in the civicrm directory within your site {:#upgrade-site-begin}
```
cd ~/buildkit/build/dmaster/sites/all/modules/civicrm/
...
...
@@ -157,7 +157,7 @@ cd ~/buildkit/build/dmaster/sites/all/modules/civicrm/
!!! note
The path to this directory will vary depending on where you installed buildkit and what CMS you site uses.
### Check the status of all git repos {:#upgrade-git-scan}
### Check the status of all git repos {:#upgrade-site-git-scan}
There are multiple git repos in your build (`civicrm-core.git`, `civicrm-packages.git`, etal). Before making a major switch, first double-check that all of these repos are in sane condition — i.e. there shouldn't be any uncommitted changes, and the repos should be on normal branches. For this purpose, use [git-scan](https://github.com/totten/git-scan), (installed with [buildkit](/tools/buildkit)).
...
...
@@ -169,7 +169,7 @@ git scan status
If you see a message like *"Fast-forwards are not possible"* or *"Modifications have not been committed"*, then you'll need to clean up these git repositories before proceeding.
### Update the git repos
### Update the git repos {:#upgrade-site-git-scan-up}
To update to the latest version of a particular branch, use `git scan up` which will perform a standard "fast-forward merge" (`git pull --ff-only`) across all the repos:
...
...
@@ -186,7 +186,7 @@ Alternatively, if you'd like to hop to a specific tag, you can use `givi` (a too
givi checkout 4.7.17
```
### Update the generated code, config files, databases
### Update the generated code, config files, databases {:#upgrade-site-update}
Reinstalling will recreate/overwrite all generated-code, config-files, and database content. Any data you put into your site (e.g. test contacts, etc) will be lost.
...
...
@@ -202,7 +202,7 @@ drush civicrm-upgrade-db
```
## Downgrading a site you installed with civibuild
## Downgrading a site you installed with civibuild {:#downgrade-site}
If you are [reviewing a pull request](/core/pr-review) you may wish to *downgrade* a civibuild site in order to begin replicating the issue and testing the fix. Currently this is **not possible** with civibuild, so instead you will need to do a [rebuild](#rebuild) with the the `--civi-ver` argument to specify your target version of CiviCRM.
...
...
@@ -260,7 +260,7 @@ There are four variations on rebuilding. In order of fastest (least thorough) to
All of these tools come bundled within [buildkit](/buildkit).
When you install [buildkit](/buildkit) you'll get all these tools.
*This list of tools is also maintained [in the buildkit readme file](https://github.com/civicrm/civicrm-buildkit/blob/master/README.md).*
### CiviCRM-specific tools {:#civicrm-specific}
*`civibuild` - Build a complete source tree (with CMS+Civi+addons), provision httpd/sql, etc.
**[documentation](/tools/civibuild.md)*
...
...
@@ -35,11 +39,9 @@ All of these tools come bundled within [buildkit](/buildkit).
**(Derived from [Drupal's coder project](https://www.drupal.org/project/coder))*
## External tools installed with buildkit
These tools are not specific to CiviCRM, so you may already have some of them installed on your system.
### External tools installed with buildkit {:#external}
If you install [buildkit](/buildkit) you'll get all these tools at once, in addition to the CiviCRM-specific tools listed above.
These tools are not specific to CiviCRM, so you may already have some of them installed on your system. If you install [buildkit](/buildkit) you'll get all these tools at once, in addition to the CiviCRM-specific tools listed above.
* Dependency management
*[composer](http://getcomposer.org/) - Manage dependencies for PHP code.
...
...
@@ -60,7 +62,14 @@ If you install [buildkit](/buildkit) you'll get all these tools at once, in addi
*[paratest](https://github.com/brianium/paratest) - Parallelized version of PHPUnit.
*[phpunit](http://phpunit.de/) - Unit testing for PHP (with Selenium and DB add-ons).
## Other useful tools
## Other useful tools {:#other}
### Miscellaneous {:#misc}
*[git](https://git-scm.com/) - version control system
*[psysh](http://psysh.org/) - a reply-echo-print-loop for PHP (like `php -a`, but better)
*[MySQL Workbench](https://www.mysql.com/products/workbench/) - A graphical interface to your local (or remote) MySQL server
*[MkDocs](http://www.mkdocs.org) - for [editing documentation](/documentation)
### Text editors
...
...
@@ -71,3 +80,4 @@ If you already have a text editor you love, then stick to that. If you're new an