Laravel\Event::listen(Laravel\Config::loader, function ($bundle, $file) { return Laravel\Config::file($bundle, $file); }); /* |-------------------------------------------------------------------------- | Register Class Aliases |-------------------------------------------------------------------------- | | Aliases allow you to use classes without always specifying their fully | namespaced path. This is convenient for working with any library that | makes a heavy use of namespace for class organization. Here we will | simply register the configured class aliases. | */ $aliases = Laravel\Config::get('application.aliases'); Laravel\Autoloader::$aliases = $aliases; /* |-------------------------------------------------------------------------- | Auto-Loader Mappings |-------------------------------------------------------------------------- | | Registering a mapping couldn't be easier. Just pass an array of class | to path maps into the "map" function of Autoloader. Then, when you | want to use that class, just use it. It's simple! | */ Autoloader::map(array('Base_Controller' => path('app') . 'controllers/base.php')); /* |-------------------------------------------------------------------------- | Auto-Loader Directories |--------------------------------------------------------------------------
$cache = Config::get('twig::config.cache'); /** * Get various other Twig configuration items */ $debug = Config::get('twig::config.debug'); $autoescape = Config::get('twig::config.autoescape'); /** * Make the cache directory if it is enabled and doesn't exist. */ if ($cache and !is_dir($cache)) { mkdir($cache); } /** * Register the Twig library with the auto-loader */ Laravel\Autoloader::underscored(array('Twig' => Bundle::path('twig') . 'lib/Twig')); /** * Instantiate a new Laravel Twig loader */ include 'loader.php'; /** * If it's registered in the IoC, resolve from there... otherwise use default */ if (IoC::registered('twig::loader')) { $loader = IoC::resolve('twig::loader'); } else { $loader = new Laravel_Twig_Loader($ext); } /** * Hook into the Laravel view loader */
<?php Laravel\Autoloader::map(array('Feed' => path('bundle') . 'feed/feed.php'));
<?php //set the bundle path Laravel\Autoloader::map(array('Delicious\\Delicious' => path('bundle') . 'delicious/delicious.php'));
/** * Bootstrapper for creating Twitter Bootstrap markup. * * @package Bundles * @subpackage Twitter * @author Patrick Talmadge - Follow @patricktalmadge * * @see http://twitter.github.com/bootstrap/ */ /** * Customized by Raftalks * ====================== * Following will help users to modify the config/application.php file * This way, removes the hassle for the bundle user. :) **/ $custom_aliases = array('Alert' => 'Bootstrapper\\Alert', 'Badges' => 'Bootstrapper\\Badges', 'Breadcrumbs' => 'Bootstrapper\\Breadcrumbs', 'Buttons' => 'Bootstrapper\\Buttons', 'ButtonGroup' => 'Bootstrapper\\ButtonGroup', 'ButtonToolbar' => 'Bootstrapper\\ButtonToolbar', 'Carousel' => 'Bootstrapper\\Carousel', 'DropdownButton' => 'Bootstrapper\\DropdownButton', 'Form' => 'Bootstrapper\\Form', 'Helpers' => 'Bootstrapper\\Helpers', 'Icons' => 'Bootstrapper\\Icons', 'Labels' => 'Bootstrapper\\Labels', 'Navbar' => 'Bootstrapper\\Navbar', 'Navigation' => 'Bootstrapper\\Navigation', 'Paginator' => 'Bootstrapper\\Paginator', 'Progress' => 'Bootstrapper\\Progress', 'SplitDropdownButton' => 'Bootstrapper\\SplitDropdownButton', 'Tabbable' => 'Bootstrapper\\Tabbable', 'Typeahead' => 'Bootstrapper\\Typeahead'); $laravel_aliases = Laravel\Autoloader::$aliases; Laravel\Autoloader::$aliases = array_merge($laravel_aliases, $custom_aliases); //<-- end of the custom addition --> Autoloader::map(array('Bootstrapper\\Alert' => __DIR__ . '/alert.php', 'Bootstrapper\\Badges' => __DIR__ . '/badges.php', 'Bootstrapper\\Breadcrumbs' => __DIR__ . '/breadcrumbs.php', 'Bootstrapper\\ButtonGroup' => __DIR__ . '/buttongroup.php', 'Bootstrapper\\Buttons' => __DIR__ . '/buttons.php', 'Bootstrapper\\ButtonToolbar' => __DIR__ . '/buttontoolbar.php', 'Bootstrapper\\Carousel' => __DIR__ . '/carousel.php', 'Bootstrapper\\DropdownButton' => __DIR__ . '/dropdownbutton.php', 'Bootstrapper\\Form' => __DIR__ . '/form.php', 'Bootstrapper\\Helpers' => __DIR__ . '/helpers.php', 'Bootstrapper\\Icons' => __DIR__ . '/icons.php', 'Bootstrapper\\Labels' => __DIR__ . '/labels.php', 'Bootstrapper\\Navbar' => __DIR__ . '/navbar.php', 'Bootstrapper\\Navigation' => __DIR__ . '/navigation.php', 'Bootstrapper\\Paginator' => __DIR__ . '/paginator.php', 'Bootstrapper\\Progress' => __DIR__ . '/progress.php', 'Bootstrapper\\SplitDropdownButton' => __DIR__ . '/splitdropdownbutton.php', 'Bootstrapper\\Tabbable' => __DIR__ . '/tabbable.php', 'Bootstrapper\\Typeahead' => __DIR__ . '/typeahead.php')); Asset::container('bootstrapper')->bundle('bootstrapper'); //Asset::container('bootstrapper')->add('jquery', 'js/jquery-1.8.0.js'); Asset::container('bootstrapper')->add('jquery', 'js/jquery-1.8.0.min.js'); //Asset::container('bootstrapper')->add('bootstrap', 'css/bootstrap.css'); Asset::container('bootstrapper')->add('bootstrap', 'css/bootstrap.min.css'); //Not Needed if you don't have the top nav bar Asset::container('bootstrapper')->add('nav-fix', 'css/nav-fix.css'); //Asset::container('bootstrapper')->add('bootstrap-responsive', 'css/bootstrap-responsive.css'); Asset::container('bootstrapper')->add('bootstrap-responsive', 'css/bootstrap-responsive.min.css'); //Asset::container('bootstrapper')->add('bootstrap-js', 'js/bootstrap.js'); Asset::container('bootstrapper')->add('bootstrap-js', 'js/bootstrap.min.js');
<?php Laravel\Autoloader::map(array('Authority' => __DIR__ . '/authority' . EXT)); Authority::initialize(Auth::user());
<?php Laravel\Autoloader::map(array('Twitter' => path('bundle') . 'twitterfeed/twitter' . EXT));
<?php //set the bundle path Laravel\Autoloader::map(array('Tumblr\\Tumblr' => path('bundle') . 'tumblr/tumblr.php'));
<?php Laravel\Autoloader::map(array('Sitemap' => path('bundle') . 'sitemap/sitemap.php'));
<?php Laravel\Autoloader::map(array('Squire_Controller' => __DIR__ . DS . 'controllers' . DS . 'squire.php', 'Squire\\Request' => __DIR__ . DS . 'libraries' . DS . 'request.php', 'Squire\\Response' => __DIR__ . DS . 'libraries' . DS . 'response.php')); class_alias('Squire\\Request', 'Request'); class_alias('Squire\\Response', 'Response'); // Load config Config::get('squire::squire'); function squire_extend_config($key, $value) { if (is_array($value) && $key != 'nav') { foreach ($value as $key1 => $value2) { squire_extend_config($key . '.' . $key1, $value2); } return; } Config::set('squire::squire.' . $key, $value); } // Apply app config foreach (Config::get('squire', array()) as $key => $value) { squire_extend_config($key, $value); } // Insert Squire JS Section::append('head', View::make('squire::sq_js')->render()); include __DIR__ . DS . 'composers.php';
<?php Laravel\Autoloader::map(array('Langbuilder\\Dir' => path('bundle') . 'language-builder/libraries/dir.php', 'Langbuilder\\Compare' => path('bundle') . 'language-builder/libraries/compare.php', 'Langbuilder\\Utilities' => path('bundle') . 'language-builder/libraries/utilities.php'));
<?php //set the bundle path Laravel\Autoloader::map(array('Appcelerator\\Appcelerator' => path('bundle') . 'appcelerator/appcelerator.php'));