Skip to content

Commit

Permalink
Laravel 5.1 support
Browse files Browse the repository at this point in the history
  • Loading branch information
kaidesu committed Jun 26, 2015
1 parent b54c06b commit 553c59b
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 29 deletions.
69 changes: 42 additions & 27 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
Caffeinated Bonsai
====================
[![Laravel](https://img.shields.io/badge/Laravel-5.0-orange.svg?style=flat-square)](http://laravel.com)
[![Laravel 5.0](https://img.shields.io/badge/Laravel-5.0-orange.svg?style=flat-square)](http://laravel.com)
[![Laravel 5.1](https://img.shields.io/badge/Laravel-5.1-orange.svg?style=flat-square)](http://laravel.com)
[![Source](http://img.shields.io/badge/source-caffeinated/bonsai-blue.svg?style=flat-square)](https://github.com/caffeinated/bonsai)
[![License](http://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)](https://tldrlegal.com/license/mit-license)

Expand All @@ -10,6 +11,46 @@ Caffeinated Bonsai is an experimental project to handle and process assets for a

The package follows the FIG standards PSR-1, PSR-2, and PSR-4 to ensure a high level of interoperability between shared PHP code. At the moment the package is not unit tested, but is planned to be covered later down the road.

Quick Installation
------------------
Begin by installing the package through Composer. Depending on what version of Laravel you are using (5.0 or 5.1), you'll want to pull in the `~1.0` or `~2.0` release, respectively:

#### Laravel 5.0.x
```
composer require caffeinated/bonsai=~1.0
```

#### Laravel 5.1.x
```
composer require caffeinated/bonsai=~2.0
```

Once this operation is complete, simply add both the service provider and facade classes to your project's `config/app.php` file:

#### Laravel 5.0.x
##### Service Provider
```php
'Caffeinated\Bonsai\BonsaiServiceProvider',
```

##### Facade
```php
'Bonsai' => 'Caffeinated\Bonsai\Facades\Bonsai',
```

#### Laravel 5.1.x
##### Service Provider
```php
Caffeinated\Bonsai\BonsaiServiceProvider::class,
```

##### Facade
```php
'Bonsai' => Caffeinated\Bonsai\Facades\Bonsai::class,
```

And that's it! With your coffee in reach, start planting some assets!

Documentation
-------------
First, plant your bonsai. You may optionally register assets during this time as well.
Expand Down Expand Up @@ -69,29 +110,3 @@ TODO
- ~~Check for dependencies (`dependsOn()` method) and load dependencies first, in order when rendering within a view.~~
- Combine and minify assets into one cached file when in the production environment.
- ~~Add the ability to parse a bonsai.json file for assets that can be registered for use.~~

Quick Installation
------------------
Begin by installing the package through Composer. Add `caffeinated/bonsai` to your composer.json file:

```
"caffeinated/bonsai": "~1.0@dev"
```

Then run `composer update` to pull the package in.

Once this operation is complete, simply add the service provider class and facade alias to your project's `config/app.php` file:

#### Service Provider

```php
'Caffeinated\Bonsai\BonsaiServiceProvider',
```

#### Facade

```php
'Bonsai' => 'Caffeinated\Bonsai\Facades\Bonsai',
```

And that's it! With your coffee in reach, start planting some assets!
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
}
],
"require": {
"php": ">=5.4.0",
"illuminate/support": "5.0.*"
"php": ">=5.5.9",
"illuminate/support": "5.1.*"
},
"require-dev": {
"phpunit/phpunit": "4.*"
Expand Down

0 comments on commit 553c59b

Please sign in to comment.