mirror of
https://github.com/filamentphp/plugin-skeleton.git
synced 2025-12-06 21:48:53 +08:00
1
.gitignore
vendored
1
.gitignore
vendored
@@ -9,4 +9,3 @@ phpstan.neon
|
|||||||
testbench.yaml
|
testbench.yaml
|
||||||
vendor
|
vendor
|
||||||
node_modules
|
node_modules
|
||||||
.DS_Store
|
|
||||||
|
|||||||
@@ -8,10 +8,8 @@ $gitEmail = run('git config user.email');
|
|||||||
$authorEmail = ask('Author email', $gitEmail);
|
$authorEmail = ask('Author email', $gitEmail);
|
||||||
|
|
||||||
$usernameGuess = explode(':', run('git config remote.origin.url'))[1];
|
$usernameGuess = explode(':', run('git config remote.origin.url'))[1];
|
||||||
if ($usernameGuess) {
|
|
||||||
$usernameGuess = dirname($usernameGuess);
|
$usernameGuess = dirname($usernameGuess);
|
||||||
$usernameGuess = basename($usernameGuess);
|
$usernameGuess = basename($usernameGuess);
|
||||||
}
|
|
||||||
$authorUsername = ask('Author username', $usernameGuess);
|
$authorUsername = ask('Author username', $usernameGuess);
|
||||||
|
|
||||||
$vendorName = ask('Vendor name', $authorUsername);
|
$vendorName = ask('Vendor name', $authorUsername);
|
||||||
@@ -85,6 +83,9 @@ if ($formsOnly) {
|
|||||||
]);
|
]);
|
||||||
} else {
|
} else {
|
||||||
if ($isTheme) {
|
if ($isTheme) {
|
||||||
|
copy(__DIR__.'/configure-stubs/theme/package.json', __DIR__.'/package.json');
|
||||||
|
copy(__DIR__.'/configure-stubs/theme/plugin.css', __DIR__.'/resources/css/plugin.css');
|
||||||
|
copy(__DIR__.'/configure-stubs/theme/tailwind.config.js', __DIR__.'/tailwind.config.js');
|
||||||
safeUnlink(__DIR__.'/src/SkeletonServiceProvider.php');
|
safeUnlink(__DIR__.'/src/SkeletonServiceProvider.php');
|
||||||
safeUnlink(__DIR__.'/src/Skeleton.php');
|
safeUnlink(__DIR__.'/src/Skeleton.php');
|
||||||
removeDirectory(__DIR__.'/config');
|
removeDirectory(__DIR__.'/config');
|
||||||
@@ -98,6 +99,9 @@ if ($formsOnly) {
|
|||||||
removeDirectory(__DIR__.'/src/Testing');
|
removeDirectory(__DIR__.'/src/Testing');
|
||||||
} else {
|
} else {
|
||||||
safeUnlink(__DIR__.'/src/SkeletonTheme.php');
|
safeUnlink(__DIR__.'/src/SkeletonTheme.php');
|
||||||
|
copy(__DIR__.'/configure-stubs/package/package.json', __DIR__.'/package.json');
|
||||||
|
copy(__DIR__.'/configure-stubs/package/plugin.css', __DIR__.'/resources/css/plugin.css');
|
||||||
|
copy(__DIR__.'/configure-stubs/package/tailwind.config.js', __DIR__.'/tailwind.config.js');
|
||||||
}
|
}
|
||||||
|
|
||||||
remove_composer_filament_deps([
|
remove_composer_filament_deps([
|
||||||
@@ -106,16 +110,6 @@ if ($formsOnly) {
|
|||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($isTheme) {
|
|
||||||
copy(__DIR__.'/configure-stubs/theme/package.json', __DIR__.'/package.json');
|
|
||||||
copy(__DIR__.'/configure-stubs/theme/plugin.css', __DIR__.'/resources/css/plugin.css');
|
|
||||||
copy(__DIR__.'/configure-stubs/theme/tailwind.config.js', __DIR__.'/tailwind.config.js');
|
|
||||||
} else {
|
|
||||||
copy(__DIR__.'/configure-stubs/admin/package.json', __DIR__.'/package.json');
|
|
||||||
copy(__DIR__.'/configure-stubs/admin/plugin.css', __DIR__.'/resources/css/plugin.css');
|
|
||||||
copy(__DIR__.'/configure-stubs/admin/tailwind.config.js', __DIR__.'/tailwind.config.js');
|
|
||||||
}
|
|
||||||
|
|
||||||
$files = (str_starts_with(strtoupper(PHP_OS), 'WIN') ? replaceForWindows() : replaceForAllOtherOSes());
|
$files = (str_starts_with(strtoupper(PHP_OS), 'WIN') ? replaceForWindows() : replaceForAllOtherOSes());
|
||||||
|
|
||||||
foreach ($files as $file) {
|
foreach ($files as $file) {
|
||||||
|
|||||||
Reference in New Issue
Block a user