savannabits / filament-modules

Integration of Filament with nWidart/laravel-modules: Create independent Filament Files for each Laravel Module
https://filamentphp.com/plugins/coolsam-modules
MIT License
109 stars 22 forks source link

[Bug]: Duplicate src in file path #101

Closed rav-redchamps closed 6 months ago

rav-redchamps commented 6 months ago

What happened?

While running command php artisan module:filament:install ModuleName & selecting cluster option to Yes got below error

Illuminate\Contracts\Filesystem\FileNotFoundException

File does not exist at path /Users/ravinder/Sites/bigcommerce/apps/share-cart/vendor/coolsam/modules/src/src/Commands/stubs/filament-plugin.stub.

You will notice that there's duplicate src folder in the path

This comes from 'src' mentioned here https://github.com/savannabits/filament-modules/blob/71316d92a4c655ae03b3a7a69be951543199f1b9/src/Concerns/GeneratesModularFiles.php#L22

Then being added again from https://github.com/savannabits/filament-modules/blob/71316d92a4c655ae03b3a7a69be951543199f1b9/src/Modules.php#L52

How to reproduce the bug

After running command php artisan module:filament:install ModuleName to install filament in existing module

Package Version

v4.0.4

PHP Version

8.2.17

Laravel Version

11.0.4

Which operating systems does with happen with?

macOS

Notes

No response

coolsam726 commented 6 months ago

Thank you for the elaborate description. This is confirmed as a bug, I am working on a fix and will merge shortly.