Skip to content

Commit

Permalink
Optimize plugin namespace (#139)
Browse files Browse the repository at this point in the history
* 规范应用 namespace

* 规范应用 namespace

---------

Co-authored-by: frank <[email protected]>
  • Loading branch information
gladtoeatu and frank authored Dec 17, 2024
1 parent ad09e83 commit 5603240
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Command/CreateCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,10 @@ public function createNamespace(string $path, string $name): string

public function createMineJson(string $path, string $name, PluginTypeEnum $pluginType): void
{
$pluginPath = Str::replace(Plugin::PLUGIN_PATH . '/', '', $path);

$output = new \stdClass();
$output->name = $name;
$output->name = $pluginPath ?? $name;
$output->version = '1.0.0';
$output->type = $pluginType->value;
$output->description = $this->input->getOption('description') ?: 'This is a sample plugin';
Expand Down

0 comments on commit 5603240

Please sign in to comment.