Publishes configuration file and registers error handler for Slack notification.

@return void
506664
public function boot()
    {
        if ($this->app->runningInConsole()) {
            $this->publishes([
                __DIR__.'/../config/cart_manager.php' => config_path('cart_manager.php'),
            ], 'laravel-cart-manager-config');

            $this->publishes([
                __DIR__.'/../database/migrations/' => database_path('migrations'),
            ], 'laravel-cart-manager-migrations');

            $this->commands([ClearCartDataCommand::class]);
        }

        CartModel::observe(CartObserver::class);
    }
342207
public function publishFiles()
    {
        // publish config file
        $this->publishes([__DIR__ . '/../config/config.php' => config_path() . '/back-project.php'], 'config');
        // publish lang files
        $this->publishes([__DIR__ . '/../resources/lang' => resource_path('lang/vendor/back-project')], 'lang');
        // publish public BackProject assets
        $this->publishes([__DIR__ . '/../public' => public_path('vendor/back-project')], 'public');
        // publish views
        $this->publishes([__DIR__ . '/../resources/views' => resource_path('views/vendor/back-project')], 'views');
        // publish error views
        $this->publishes([__DIR__ . '/../resources/error_views' => resource_path('views/errors')], 'errors');
        // publish public AdminLTE assets
        $this->publishes(['vendor/almasaeed2010/adminlte/bower_components/bootstrap/dist' => public_path('vendor/adminlte/bootstrap')], 'adminlte');
        $this->publishes(['vendor/almasaeed2010/adminlte/dist' => public_path('vendor/adminlte/dist')], 'adminlte');
        $this->publishes(['vendor/almasaeed2010/adminlte/plugins' => public_path('vendor/adminlte/plugins')], 'adminlte');
    }
1264802
private function publishFiles()
    {
        $publishTag = 'laravel2step';

        $this->publishes([
            __DIR__.'/config/laravel2step.php' => base_path('config/laravel2step.php'),
        ], $publishTag);

        $this->publishes([
            __DIR__.'/database/migrations/' => base_path('/database/migrations'),
        ], $publishTag);

        $this->publishes([
            __DIR__.'/public/css' => public_path('css/laravel2step'),
        ], $publishTag);

        $this->publishes([
            __DIR__.'/resources/assets/scss' => resource_path('assets/scss/laravel2step'),
        ], $publishTag);

        $this->publishes([
            __DIR__.'/resources/views' => resource_path('views/vendor/laravel2step'),
        ], $publishTag);

        $this->publishes([
            __DIR__.'/resources/lang' => base_path('resources/lang/vendor/laravel2step'),
        ], $publishTag);
    }
782974
private function registerFileConfig()
    {
        $this->app->singleton('config', function ($app) {
            $loader = $app->make('Concrete\Core\Config\FileLoader');
            $saver = $app->make('Concrete\Core\Config\FileSaver');

            return $app->build('Concrete\Core\Config\Repository\Repository', array($loader, $saver, $app->environment()));
        });
    }
1036107
protected function publishConfig()
    {
        // Publish config files
        $this->publishes([
            __DIR__.'/../../config/config.php'           => config_path('vat_calculator.php'),
            __DIR__.'/../../public/js/vat_calculator.js' => public_path('js/vat_calculator.js'),
        ]);

        $this->publishes([
            __DIR__.'/../../public/js/vat_calculator.js' => base_path('resources/assets/js/vat_calculator.js'),
        ], 'vatcalculator-spark');
    }
390020
public function onConfigUpdated()
    {
        if (Daemon::$process instanceof Thread\Worker) {
            if ($this->config === null) {
                $this->disable();
            } else {
                $this->enable();
            }
        }
        if ($defaults = $this->getConfigDefaults()) {
            $this->config->imposeDefault($defaults);
        }
        $this->applyConfig();
    }
918890
function updateConfiguration()
    {
        info('Updating PHP configuration...');

        $contents = $this->files->get($this->fpmConfigPath());

        $contents = preg_replace('/^user = .+$/m', 'user = '.user(), $contents);
        $contents = preg_replace('/^group = .+$/m', 'group = staff', $contents);
        $contents = preg_replace('/^listen = .+$/m', 'listen = '.VALET_HOME_PATH.'/valet.sock', $contents);
        $contents = preg_replace('/^;?listen\.owner = .+$/m', 'listen.owner = '.user(), $contents);
        $contents = preg_replace('/^;?listen\.group = .+$/m', 'listen.group = staff', $contents);
        $contents = preg_replace('/^;?listen\.mode = .+$/m', 'listen.mode = 0777', $contents);

        $this->files->put($this->fpmConfigPath(), $contents);


        $contents = $this->files->get(__DIR__.'/../stubs/php-memory-limits.ini');

        $destFile = dirname($this->fpmConfigPath());
        $destFile = str_replace('/php-fpm.d', '', $destFile);
        $destFile .= '/conf.d/php-memory-limits.ini';
        $this->files->ensureDirExists(dirname($destFile), user());

        $this->files->putAsUser($destFile, $contents);
    }
1299116
public function actionConfigInfo()
    {
        $this->outputInfo("dev config file: " . Yii::getAlias($this->configFile));
        
        $config = $this->readConfig();
        
        if (!$config) {
            return $this->outputError("Unable to open config file.");
        }
        
        foreach ($config as $key => $value) {
            $this->output("{$key} => ".VarDumper::dumpAsString($value));
        }
    }
1127239
private function publishConfig($register)
    {
        $src = $this->path . '/config.php';
        if (!file_exists($src)) {
            return;
        }

        $dest = config_path($this->plugin . '.php');
        if (file_exists($dest)) {
            return;
        }

        if ($register) {
            copy($src, $dest);
        }
    }
142912
protected function registerConfig() {
        $config = new Configuration($this->configFile);
        $this->container->set('config', function() use ($config) {
                return $config;
        });
    }
258610
protected function publishFiles()
    {
        $this->publishes([
            __DIR__.'/../Config/installer.php' => base_path('config/installer.php'),
        ], 'laravelinstaller');

        $this->publishes([
            __DIR__.'/../assets' => public_path('installer'),
        ], 'laravelinstaller');

        $this->publishes([
            __DIR__.'/../Views' => base_path('resources/views/vendor/installer'),
        ], 'laravelinstaller');

        $this->publishes([
            __DIR__.'/../Lang' => base_path('resources/lang'),
        ], 'laravelinstaller');
    }
908316
private function publishResources()
    {
        $this->publishes([__DIR__.'/../../resources/config/defender.php' => config_path('defender.php')], 'config');
        $this->mergeConfigFrom(__DIR__.'/../../resources/config/defender.php', 'defender');
        $this->loadViewsFrom(__DIR__.'/../../resources/views', 'defender');
    }
535953
public function boot()
    {
        $this->publishes(array(
            __DIR__ . '/../../config/config.php' => config_path('epilog.php')
        ));

        $logger = \Log::getMonolog();

        // Additional info in message
        $logger->pushProcessor(function($record) {
            $info = '';
            if (\Auth::check()) {
                $info .= 'User #' . \Auth::user()->id . ' (' . \Auth::user()->email . ') - ';
            }
            if (isset($_SERVER['REMOTE_ADDR'])) {
                $info .= 'IP: ' . $_SERVER['REMOTE_ADDR'];
            }
            if (isset($_SERVER['REQUEST_URI'])) {
                $info .= "\n" . $_SERVER['REQUEST_METHOD'] . " " . url($_SERVER['REQUEST_URI']);
            }
            if (isset($_SERVER['HTTP_REFERER'])) {
                $info .= "\nReferer: " . $_SERVER['HTTP_REFERER'];
            }
            if ($info) {
                $info = "\n---\n$info\n---";
                if (strpos($record['message'], "\n")) {
                    $record['message'] = preg_replace("/\n/", $info . "\n", $record['message'], 1);
                } else {
                    $record['message'] .= $info . "\n";
                }
            }
            return $record;
        });

        // Slack notification
        if (app()->environment(config('epilog.slack.env'))) {
            $slackHandler = new \Monolog\Handler\SlackHandler(
                config('epilog.slack.token'),
                config('epilog.slack.channel'),
                config('epilog.slack.username'),
                true,
                ':skull:',
                \Monolog\Logger::ERROR,
                true,
                true,
                true
            );
            $logger->pushHandler($slackHandler);
        }

    }
1323052
public function setup() {
		$this->errorHandler = $errorHandler = \Asgard\Debug\ErrorHandler::register();
		if(php_sapi_name() !== 'cli')
			\Asgard\Debug\Debug::setFormat('html');

		register_shutdown_function([$this, 'shutdownFunction']);
		$this->addShutdownCallback([$errorHandler, 'shutdownFunction']);

		$compiledFile = $this->getCompiledFile();
		if($compiledFile && file_exists($compiledFile))
			include_once $compiledFile;

		return $this;
	}
998574
protected function loadConfiguration()
    {
        $configPath = __DIR__ . '/../config/onesky.php';

        $this->publishes([
            $configPath => config_path('onesky.php'),
        ], 'config');

        $this->mergeConfigFrom($configPath, 'onesky');
    }
542892
protected function registerConfig()
    {
        $this->publishes([
            realpath(PLATFORM_PATH.'/config/press.php') => config_path('press.php'),
        ], 'config');

        $this->mergeConfigFrom(
            realpath(PLATFORM_PATH.'/config/press.php'), 'press'
        );

        return $this;
    }
1097415
protected function setupConfig()
    {
        $path = realpath(__DIR__."/../../config/gravatar-helper.php");

        $this->publishes([$path => config_path("gravatar-helper.php")]);

        $this->mergeConfigFrom($path, 'gravatar-helper');
    }