2016-04-11 21:02:59 -06:00
#  Grav
2015-02-18 22:21:38 -07:00
2017-01-30 18:45:14 -07:00
[](https://insight.sensiolabs.com/projects/cfd20465-d0f8-4a0a-8444-467f5b5f16ad) [](https://chat.getgrav.org) [](https://travis-ci.org/getgrav/grav) [](#backers ) [](#sponsors )
2014-08-02 11:29:10 -07:00
2015-04-17 10:59:03 -07:00
Grav is a **Fast** , **Simple** , and **Flexible** , file-based Web-platform. There is **Zero** installation required. Just extract the ZIP archive, and you are already up and running. It follows similar principles to other flat-file CMS platforms, but has a different design philosophy than most. Grav comes with a powerful **Package Management System** to allow for simple installation and upgrading of plugins and themes, as well as simple updating of Grav itself.
2014-08-11 10:49:54 -07:00
2015-10-15 16:28:06 -04:00
The underlying architecture of Grav is designed to use well-established and _best-in-class_ technologies to ensure that Grav is simple to use and easy to extend. Some of these key technologies include:
2014-08-11 10:49:54 -07:00
* [Twig Templating ](http://twig.sensiolabs.org/ ): for powerful control of the user interface
* [Markdown ](http://en.wikipedia.org/wiki/Markdown ): for easy content creation
* [YAML ](http://yaml.org ): for simple configuration
2015-10-28 17:55:23 +09:00
* [Parsedown ](http://parsedown.org/ ): for fast Markdown and Markdown Extra support
2016-06-09 02:49:04 -04:00
* [Doctrine Cache ](http://doctrine-orm.readthedocs.io/projects/doctrine-orm/en/latest/reference/caching.html ): layer for performance
2014-08-30 14:34:47 -06:00
* [Pimple Dependency Injection Container ](http://pimple.sensiolabs.org/ ): for extensibility and maintainability
2015-10-28 19:58:38 -07:00
* [Symfony Event Dispatcher ](http://symfony.com/doc/current/components/event_dispatcher/introduction.html ): for plugin event handling
2014-08-30 14:34:47 -06:00
* [Symfony Console ](http://symfony.com/doc/current/components/console/introduction.html ): for CLI interface
* [Gregwar Image Library ](https://github.com/Gregwar/Image ): for dynamic image manipulation
2014-08-11 10:49:54 -07:00
2015-08-16 09:10:53 +02:00
# Requirements
2017-02-08 10:55:57 -07:00
- PHP 5.5.9 or higher. Check the [required modules list ](https://learn.getgrav.org/basics/requirements#php-requirements )
- Check the [Apache ](https://learn.getgrav.org/basics/requirements#apache-requirements ) or [IIS ](https://learn.getgrav.org/basics/requirements#iis-requirements ) requirements
2015-08-16 09:10:53 +02:00
2014-08-13 14:13:14 -05:00
# QuickStart
2014-08-12 16:52:47 -06:00
2016-01-05 11:14:04 +01:00
These are the options to get Grav:
2014-08-12 16:52:47 -06:00
### Downloading a Grav Package
2017-02-08 10:55:57 -07:00
You can download a **ready-built** package from the [Downloads page on https://getgrav.org ](https://getgrav.org/downloads )
2014-08-12 16:52:47 -06:00
2016-04-11 21:02:59 -06:00
### With Composer
2016-01-05 11:14:04 +01:00
You can create a new project with the latest **stable** Grav release with the following command:
```
$ composer create-project getgrav/grav ~/webroot/grav
```
2014-08-12 16:52:47 -06:00
### From GitHub
1. Clone the Grav repository from [https://github.com/getgrav/grav]() to a folder in the webroot of your server, e.g. `~/webroot/grav` . Launch a **terminal** or **console** and navigate to the webroot folder:
```
$ cd ~/webroot
$ git clone https://github.com/getgrav/grav.git
```
2017-02-08 10:55:57 -07:00
2. Install the **plugin** and **theme dependencies** by using the [Grav CLI application ](https://learn.getgrav.org/advanced/grav-cli ) `bin/grav` :
2014-08-12 16:52:47 -06:00
```
$ cd ~/webroot/grav
$ bin/grav install
```
2017-02-08 10:55:57 -07:00
Check out the [install procedures ](https://learn.getgrav.org/basics/installation ) for more information.
2014-08-12 16:52:47 -06:00
2014-12-05 11:33:30 -07:00
# Adding Functionality
2017-02-08 10:55:57 -07:00
You can download [plugins ](https://getgrav.org/downloads/plugins ) or [themes ](https://getgrav.org/downloads/themes ) manually from the appropriate tab on the [Downloads page on https://getgrav.org ](https://getgrav.org/downloads ), but the preferred solution is to use the [Grav Package Manager ](https://learn.getgrav.org/advanced/grav-gpm ) or `GPM` :
2014-12-05 11:33:30 -07:00
```
$ bin/gpm index
```
2015-10-28 17:55:23 +09:00
This will display all the available plugins and then you can install one or more with:
2014-12-05 11:33:30 -07:00
```
$ bin/gpm install < plugin / theme >
```
# Updating
2017-02-08 10:55:57 -07:00
To update Grav you should use the [Grav Package Manager ](https://learn.getgrav.org/advanced/grav-gpm ) or `GPM` :
2014-12-05 11:33:30 -07:00
```
$ bin/gpm selfupgrade
```
To update plugins and themes:
```
$ bin/gpm update
```
2014-08-11 10:49:54 -07:00
2014-08-15 13:26:02 -07:00
# Contributing
We appreciate any contribution to Grav, whether it is related to bugs, grammar, or simply a suggestion or improvement.
2015-10-28 16:25:29 -05:00
However, we ask that any contributions follow our simple guidelines in order to be properly received.
2014-08-15 13:26:02 -07:00
2014-08-15 15:31:49 -05:00
All our projects follow the [GitFlow branching model][gitflow-model], from development to release. If you are not familiar with it, there are several guides and tutorials to make you understand what it is about.
2014-08-15 13:26:02 -07:00
You will probably want to get started by installing [this very good collection of git extensions][gitflow-extensions].
What you mainly want to know is that:
2014-08-15 15:31:49 -05:00
- All the main activity happens in the `develop` branch. Any pull request should be addressed only to that branch. We will not consider pull requests made to the `master` .
2014-08-15 13:26:02 -07:00
- It's very well appreciated, and highly suggested, to start a new feature whenever you want to make changes or add functionalities. It will make it much easier for us to just checkout your feature branch and test it, before merging it into `develop`
2014-08-13 14:13:14 -05:00
# Getting Started
2017-02-08 10:55:57 -07:00
* [What is Grav? ](https://learn.getgrav.org/basics/what-is-grav )
* [Install ](https://learn.getgrav.org/basics/installation ) Grav in few seconds
* Understand the [Configuration ](https://learn.getgrav.org/basics/grav-configuration )
* Take a peek at our available free [Skeletons ](https://getgrav.org/downloads/skeletons )
* If you have questions, jump on our [Slack Room ](https://getgrav.org/slack )!
2014-08-11 13:01:11 -05:00
* Have fun!
2014-08-11 10:49:54 -07:00
2016-01-10 19:22:23 +01:00
# Exploring More
2014-08-13 14:13:14 -05:00
2017-02-08 10:55:57 -07:00
* Have a look at our [Basic Tutorial ](https://learn.getgrav.org/basics/basic-tutorial )
* Dive into more [advanced ](https://learn.getgrav.org/advanced ) functions
2014-08-11 10:49:54 -07:00
2017-01-30 11:47:09 -08:00
# Backers
Support us with a monthly donation and help us continue our activities. [[Become a backer ](https://opencollective.com/grav#backer )]
< a href = "https://opencollective.com/grav/backer/0/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/0/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/1/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/1/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/2/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/2/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/3/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/3/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/4/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/4/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/5/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/5/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/6/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/6/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/7/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/7/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/8/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/8/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/9/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/9/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/10/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/10/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/11/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/11/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/12/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/12/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/13/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/13/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/14/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/14/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/15/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/15/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/16/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/16/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/17/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/17/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/18/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/18/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/19/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/19/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/20/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/20/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/21/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/21/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/22/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/22/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/23/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/23/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/24/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/24/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/25/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/25/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/26/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/26/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/27/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/27/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/28/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/28/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/backer/29/website" target = "_blank" > < img src = "https://opencollective.com/grav/backer/29/avatar.svg" > < / a >
# Sponsors
Become a sponsor and get your logo on our README on Github with a link to your site. [[Become a sponsor ](https://opencollective.com/grav#sponsor )]
2017-02-15 15:14:51 -08:00
2017-01-30 11:47:09 -08:00
< a href = "https://opencollective.com/grav/sponsor/0/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/0/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/1/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/1/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/2/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/2/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/3/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/3/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/4/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/4/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/5/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/5/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/6/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/6/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/7/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/7/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/8/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/8/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/9/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/9/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/10/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/10/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/11/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/11/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/12/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/12/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/13/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/13/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/14/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/14/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/15/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/15/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/16/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/16/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/17/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/17/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/18/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/18/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/19/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/19/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/20/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/20/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/21/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/21/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/22/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/22/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/23/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/23/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/24/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/24/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/25/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/25/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/26/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/26/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/27/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/27/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/28/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/28/avatar.svg" > < / a >
< a href = "https://opencollective.com/grav/sponsor/29/website" target = "_blank" > < img src = "https://opencollective.com/grav/sponsor/29/avatar.svg" > < / a >
2014-08-13 14:13:14 -05:00
# License
2015-12-06 13:24:27 -08:00
See [LICENSE ](LICENSE.txt )
2014-08-15 13:26:02 -07:00
[gitflow-model]: http://nvie.com/posts/a-successful-git-branching-model/
2014-08-15 15:31:49 -05:00
[gitflow-extensions]: https://github.com/nvie/gitflow
2016-01-10 19:22:23 +01:00
# Running Tests
First install the dev dependencies by running `composer update` from the Grav root.
2016-01-21 12:41:32 +01:00
Then `composer test` will run the Unit Tests, which should be always executed successfully on any site.
2016-01-22 10:39:36 +01:00
You can also run a single unit test file, e.g. `composer test tests/unit/Grav/Common/AssetsTest.php`