/** * Execute the console command. * * @return void */ public function fire() { $this->info('for more information visit https://github.com/d11wtq/boris'); $this->info('press CTRL-D to exit'); $boris = new \Boris\Boris('smith> '); $boris->start(); }
/** * @param InputInterface $input * @param OutputInterface $output * * @return int|null|void */ protected function execute(InputInterface $input, OutputInterface $output) { $boris = new \Boris\Boris('Seriis> '); $boris->onStart('$app = \\Seriis\\SeriisApp::getInstance();'); $boris->onStart('$db = $app->Db;'); $boris->onStart('$db->persistence = false;'); $boris->onStart('$cache = $app->Cache;'); $boris->onStart('echo "Welcome to Boris.\\n Quick usage functions: \\$app, \\$db, \\$cache \\n more to come \\n";'); $boris->start(); }
<?php require realpath(__DIR__ . '/../vendor/autoload.php'); require 'drupal_bootstrap.php'; $boris = new \Boris\Boris('drupal> '); $boris->start();
public function execute(InputInterface $input, OutputInterface $output) { $boris = new \Boris\Boris(sprintf('%s%s ', $this->shellName, $this->delimiter)); $boris->setLocal(array('container' => $this->getContainer())); $boris->start(); }
<?php /** * Load Boris REPL when run via `php index.php boris`. */ if (!$this->cli) { die('Must be run from the command line.'); } require_once 'lib/vendor/autoload.php'; $boris = new \Boris\Boris('elefant> '); $boris->setLocal(array('cache' => $cache, 'controller' => $this, 'i18n' => $i18n, 'page' => $page, 'tpl' => $tpl)); $boris->start();