2017 © Pedro Peláez
 

library workbench

adds configurable workbench management commands to laravel

image

artistan/workbench

adds configurable workbench management commands to laravel

  • Wednesday, January 21, 2015
  • by Artistan
  • Repository
  • 1 Watchers
  • 2 Stars
  • 123 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 14 Versions
  • 0 % Grown

The README.md

Workbench Helper for Laravel

adds configurable workbench management commands to laravel, (*1)

Composer Configuration

Include the artistan workbench package as a dependency in your composer.json Packagist:, (*2)

"require-dev": {
    "artistan/workbench": "*"
},

Installation

Once you update your composer configuration, run composer install to download the dependencies., (*3)

Add a ServiceProvider to your providers array in app/config/app.php:, (*4)

'providers' => array(

    'Artistan\Workbench\WorkbenchServiceProvider',

)

Finally, publish the configuration files via `php artisan config:publish artistan/workbench`.

Configuration

Once you have published the configuration files, you can add your workbench package options to the config file in app/config/packages/artistan/workbench/config.php., (*5)

/*
 * config for commands workbench:*
 */
'packages'=>[
    'vendor/package'=>[
        'git'=>'git@github.com:vendor/devPackage.git',
        'remotes'=>[
            'upstream'=>'git@github.com:vendor/masterPackage.git',
            'upstream2'=>'git@github.com:vendor/masterPackage.git',
        ]
    ],
]

Usage

Command Line Interface, (*6)

php artisan workbench:install

    OPTIONS:
        -d          : destroy workbench directory and start over from scratch
        -u          : fetch the remote repositories
        -m{string}  : merge {remote name} with this branch locally
        -c          : skip composer install/update
        -b          : skip bower install
        -p          : skip publishing assets and configs

Details

  • update storage permissions
  • get packages config ** de, (*7)

    $this->benchhelper->chStorage();
    $packages = \Config::get('workbench::packages');
    if($this->option('destroy')){
        if ($this->confirm('Are you sure you want to remove all current workbench packages? [yes|no]'))
        {
            $this->benchhelper->destroy();
        }
    }
    foreach($packages as $name=>$package){
        echo "PACKAGE: $name\n";
        if(isset($package['git'])){
            $this->benchhelper->mkdir($name);
            $action = $this->benchhelper->getGit($name,$package);
            if($this->option('upstream')){
                echo "upstream\n";
                $this->benchhelper->getUpstream($name,$package,$this->option('merge'));
            }
            if(!$this->option('skipBower')){
                $this->benchhelper->bower($name);
            }
            if(!$this->option('skipComposer')){
                $this->benchhelper->composer($name,$action);
            }
            if(!$this->option('skipAssets')){
                $this->call('asset:publish', array('--bench' => $name));
            }
            if($this->option('publishConfigs') || $action=='install'){
                // this should not be done all the time, first time only (install)
                $this->call('config:publish', array('argument' => $name, '--path' => 'workbench/'.$name.'/src/config'));
            }
        }
        echo "============================\n\n\n";
    }
    if(!$this->option('skipBower')){
        $this->benchhelper->bower();
    }
    if(!$this->option('skipComposer')){
        $this->benchhelper->composer();
        // remove any packages from vendors directory that you are workbenching
        $this->benchhelper->composerVendorCleanup(array_keys($packages));
    }
    //$this->call('command:name', array('argument' => 'foo', '--option' => 'bar'));

The Versions

21/01 2015

dev-master

9999999-dev

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

29/09 2014

0.3

0.3.0.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

02/07 2014

0.2.4

0.2.4.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

02/07 2014

0.2.3

0.2.3.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

01/07 2014

0.2.2

0.2.2.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

01/07 2014

0.2.1

0.2.1.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

30/06 2014

0.2.0

0.2.0.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

30/06 2014

0.1.5

0.1.5.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

30/06 2014

0.1.6

0.1.6.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

30/06 2014

0.1.4

0.1.4.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

27/06 2014

0.1.3

0.1.3.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

27/06 2014

0.1.2

0.1.2.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

27/06 2014

0.1.1

0.1.1.0

adds configurable workbench management commands to laravel

  Sources   Download

GPL-3.0+

The Requires

 

by Artistan (Charles Peterson)

laravel helpers laravel4 workbench artistan

27/06 2014

0.1

0.1.0.0

adds configurable workbench management commands to laravel

  Sources   Download

The Requires

 

by Artistan (Charles Peterson)