Skip to content

Commit 81f0c3b

Browse files
authored
Vishal/fixes (#1031)
1 parent 546efd9 commit 81f0c3b

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

src/Commands/Publish/PublishBaseCommand.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,15 @@ public function publishDirectory(string $sourceDir, string $destinationDir, stri
3939
return true;
4040
}
4141

42+
protected function confirmOverwrite(string $fileName, string $prompt = ''): bool
43+
{
44+
$prompt = (empty($prompt))
45+
? $fileName.' already exists. Do you want to overwrite it? [y|N]'
46+
: $prompt;
47+
48+
return $this->confirm($prompt, false);
49+
}
50+
4251
/**
4352
* Get the console command options.
4453
*

views/scaffold/user/user_repository.blade.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
<?php
1+
@php
2+
echo "<?php".PHP_EOL;
3+
@endphp
24

35
namespace {{ config('laravel_generator.namespace.repository') }};
46

0 commit comments

Comments
 (0)