| @@ 272-274 (lines=3) @@ | ||
| 269 | if ($this->filesystem->exists($path = $this->getPath()) && ! $this->force) { |
|
| 270 | throw new FileAlreadyExistsException($path); |
|
| 271 | } |
|
| 272 | if (! $this->filesystem->isDirectory($dir = dirname($path))) { |
|
| 273 | $this->filesystem->makeDirectory($dir, 0777, true, true); |
|
| 274 | } |
|
| 275 | ||
| 276 | return $this->filesystem->put($path, $this->getStub()); |
|
| 277 | } |
|
| @@ 177-179 (lines=3) @@ | ||
| 174 | if ( ! $this->filesystem->exists($path) || $this->confirm($path.' already exists! Continue?')) { |
|
| 175 | $content = str_replace('$NAMESPACE$', $namespace, $stub); |
|
| 176 | ||
| 177 | if (! $this->filesystem->isDirectory($dir = dirname($path))) { |
|
| 178 | $this->filesystem->makeDirectory($dir, 0777, true, true); |
|
| 179 | } |
|
| 180 | ||
| 181 | $this->filesystem->put($path, $content); |
|
| 182 | $this->line('---------------'); |
|