Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
etrepat committed Apr 29, 2013
0 parents commit ac14237
Show file tree
Hide file tree
Showing 12 changed files with 149 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/vendor
composer.phar
composer.lock
.DS_Store
11 changes: 11 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
language: php

php:
- 5.3
- 5.4

before_script:
- curl -s http://getcomposer.org/installer | php
- php composer.phar install --dev

script: phpunit
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) 2013 Estanislau Trepat

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Baum

Baum is an implementation of the [Nested Set](http://en.wikipedia.org/wiki/Nested_set_model)
pattern for [Laravel 4's](http://laravel.com/) Eloquent ORM.

## License

Baum is licensed under the terms of the [MIT License](http://opensource.org/licenses/MIT)
(See LICENSE file for details).

---

Coded by Estanislau Trepat.
28 changes: 28 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"name": "etrepat/baum",
"type": "library",
"description": "Baum is an implementation of the Nested Set pattern for Eloquent models.",
"keywords": ["nested set", "laravel 4", "eloquent", "database"],
"license": "MIT",
"authors": [
{
"name": "Estanislau Trepat",
"email": "[email protected]",
"homepage": "http://etrepat.com"
}
],
"require": {
"php": ">=5.3.0",
"illuminate/support": "4.0.x",
"illuminate/database": "4.0.x"
},
"require-dev": {
"phpunit/phpunit": "3.7.*"
},
"autoload": {
"psr-0": {
"Baum": "src/"
}
},
"minimum-stability": "dev"
}
18 changes: 18 additions & 0 deletions phpunit.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit backupGlobals="false"
backupStaticAttributes="false"
bootstrap="vendor/autoload.php"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false"
syntaxCheck="false"
>
<testsuites>
<testsuite name="Package Test Suite">
<directory suffix=".php">./tests/</directory>
</testsuite>
</testsuites>
</phpunit>
46 changes: 46 additions & 0 deletions src/Baum/BaumServiceProvider.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?php
namespace Baum;

use Illuminate\Support\ServiceProvider;

class BaumServiceProvider extends ServiceProvider {

/**
* Indicates if loading of the provider is deferred.
*
* @var bool
*/
protected $defer = false;

/**
* Bootstrap the application events.
*
* @return void
*/
public function boot()
{
$this->package('etrepat/baum');
}

/**
* Register the service provider.
*
* @return void
*/
public function register()
{
//
}

/**
* Get the services provided by the provider.
*
* @return array
*/
public function provides()
{
// return array();
return array('node');
}

}
8 changes: 8 additions & 0 deletions src/Baum/Node.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?php
namespace Baum;

use Illuminate\Database\Eloquent\Model;

abstract class Node extends Model {

}
Empty file added src/config/.gitkeep
Empty file.
Empty file added src/lang/.gitkeep
Empty file.
Empty file added src/migrations/.gitkeep
Empty file.
Empty file added tests/.gitkeep
Empty file.

0 comments on commit ac14237

Please sign in to comment.