Skip to content
This repository was archived by the owner on Feb 18, 2024. It is now read-only.

Commit df52645

Browse files
author
atehnix
committed
Added new stubs
1 parent b230b6d commit df52645

File tree

4 files changed

+18
-3
lines changed

4 files changed

+18
-3
lines changed

src/Console/MailMakeCommand.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,11 @@ class MailMakeCommand extends BaseMailMakeCommand
2020
*/
2121
protected function getStub()
2222
{
23-
$stub = config('stubs.path').'/mail.stub';
23+
if ($this->option('markdown')) {
24+
$stub = config('stubs.path').'/markdown-mail.stub';
25+
} else {
26+
$stub = config('stubs.path').'/mail.stub';
27+
}
2428

2529
return file_exists($stub) ? $stub : parent::getStub();
2630
}

src/Console/NotificationMakeCommand.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,11 @@ class NotificationMakeCommand extends BaseNotificationMakeCommand
2020
*/
2121
protected function getStub()
2222
{
23-
$stub = config('stubs.path').'/notification.stub';
23+
if ($this->option('markdown')) {
24+
$stub = config('stubs.path').'/markdown-notification.stub';
25+
} else {
26+
$stub = config('stubs.path').'/notification.stub';
27+
}
2428

2529
return file_exists($stub) ? $stub : parent::getStub();
2630
}

src/Console/StubsPublishCommand.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,13 +56,16 @@ class StubsPublishCommand extends Command
5656
'Illuminate/Foundation/Console/stubs/listener.stub',
5757
'Illuminate/Foundation/Console/stubs/listener-queued.stub',
5858
'Illuminate/Foundation/Console/stubs/mail.stub',
59+
'Illuminate/Foundation/Console/stubs/markdown-mail.stub',
5960
'Illuminate/Foundation/Console/stubs/model.stub',
6061
'Illuminate/Foundation/Console/stubs/notification.stub',
62+
'Illuminate/Foundation/Console/stubs/markdown-notification.stub',
6163
'Illuminate/Foundation/Console/stubs/policy.plain.stub',
6264
'Illuminate/Foundation/Console/stubs/policy.stub',
6365
'Illuminate/Foundation/Console/stubs/provider.stub',
6466
'Illuminate/Foundation/Console/stubs/request.stub',
6567
'Illuminate/Foundation/Console/stubs/test.stub',
68+
'Illuminate/Foundation/Console/stubs/unit-test.stub',
6669
'Illuminate/Routing/Console/stubs/controller.plain.stub',
6770
'Illuminate/Routing/Console/stubs/controller.model.stub',
6871
'Illuminate/Routing/Console/stubs/controller.stub',

src/Console/TestMakeCommand.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,11 @@ class TestMakeCommand extends BaseTestMakeCommand
2020
*/
2121
protected function getStub()
2222
{
23-
$stub = config('stubs.path').'/test.stub';
23+
if ($this->option('unit')) {
24+
$stub = config('stubs.path').'/unit-test.stub';
25+
} else {
26+
$stub = config('stubs.path').'/test.stub';
27+
}
2428

2529
return file_exists($stub) ? $stub : parent::getStub();
2630
}

0 commit comments

Comments
 (0)