This repository was archived by the owner on Jul 18, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathartisan
More file actions
51 lines (41 loc) · 1.4 KB
/
artisan
File metadata and controls
51 lines (41 loc) · 1.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#!/usr/bin/env php
<?php
$fromPackage = __DIR__."/../../autoload.php";
if (file_exists($fromPackage)) {
require_once $fromPackage;
} else {
require_once "./vendor/autoload.php";
}
use Symfony\Component\Console\Input\ArgvInput;
use Symfony\Component\Console\Output\ConsoleOutput;
/*
|--------------------------------------------------------------------------
| Create The Application
|--------------------------------------------------------------------------
|
| First we need to get an application instance. This creates an instance
| of the application / container and bootstraps the application so it
| is ready to receive HTTP / Console requests from the environment.
|
*/
/*
|--------------------------------------------------------------------------
| Run The Artisan Application
|--------------------------------------------------------------------------
|
| When we run the console application, the current CLI command will be
| executed in this console and the response sent back to a terminal
| or another output device for the developers. Here goes nothing!
|
*/
$app = new Moon\Artisan\Stub\Application;
$app->singleton(
'Illuminate\Contracts\Debug\ExceptionHandler',
'Moon\\Artisan\Exceptions\Handler'
);
$app->instance('path', getcwd());
$kernel = new Moon\Artisan\Console\Kernel(
$app,
new Moon\Artisan\Stub\Dispatcher()
);
exit($kernel->handle(new ArgvInput, new ConsoleOutput));