aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/src/plugin
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-06-28 17:45:06 +0900
committernsfisis <nsfisis@gmail.com>2026-06-28 17:45:26 +0900
commit53f1fb395f33e0fb8db9aebd09ea9082f650f9f1 (patch)
treef9e8bf0e9d4b1e98cce383574fb6a13b684fff08 /crates/shirabe/src/plugin
parent212f5cd75b1403ee75ffa44d7ebdb181174340c0 (diff)
downloadphp-shirabe-53f1fb395f33e0fb8db9aebd09ea9082f650f9f1.tar.gz
php-shirabe-53f1fb395f33e0fb8db9aebd09ea9082f650f9f1.tar.zst
php-shirabe-53f1fb395f33e0fb8db9aebd09ea9082f650f9f1.zip
refactor: add linter
Diffstat (limited to 'crates/shirabe/src/plugin')
-rw-r--r--crates/shirabe/src/plugin/capability.rs (renamed from crates/shirabe/src/plugin/capability/mod.rs)0
-rw-r--r--crates/shirabe/src/plugin/mod.rs23
-rw-r--r--crates/shirabe/src/plugin/plugin_manager.rs16
-rw-r--r--crates/shirabe/src/plugin/post_file_download_event.rs5
-rw-r--r--crates/shirabe/src/plugin/pre_file_download_event.rs5
-rw-r--r--crates/shirabe/src/plugin/pre_pool_create_event.rs6
6 files changed, 13 insertions, 42 deletions
diff --git a/crates/shirabe/src/plugin/capability/mod.rs b/crates/shirabe/src/plugin/capability.rs
index 5b7dcea..5b7dcea 100644
--- a/crates/shirabe/src/plugin/capability/mod.rs
+++ b/crates/shirabe/src/plugin/capability.rs
diff --git a/crates/shirabe/src/plugin/mod.rs b/crates/shirabe/src/plugin/mod.rs
deleted file mode 100644
index a26e117..0000000
--- a/crates/shirabe/src/plugin/mod.rs
+++ /dev/null
@@ -1,23 +0,0 @@
-pub mod capability;
-pub mod capable;
-pub mod command_event;
-pub mod plugin_blocked_exception;
-pub mod plugin_events;
-pub mod plugin_interface;
-pub mod plugin_manager;
-pub mod post_file_download_event;
-pub mod pre_command_run_event;
-pub mod pre_file_download_event;
-pub mod pre_pool_create_event;
-
-pub use capability::*;
-pub use capable::*;
-pub use command_event::*;
-pub use plugin_blocked_exception::*;
-pub use plugin_events::*;
-pub use plugin_interface::*;
-pub use plugin_manager::*;
-pub use post_file_download_event::*;
-pub use pre_command_run_event::*;
-pub use pre_file_download_event::*;
-pub use pre_pool_create_event::*;
diff --git a/crates/shirabe/src/plugin/plugin_manager.rs b/crates/shirabe/src/plugin/plugin_manager.rs
index a949c03..dd68d1e 100644
--- a/crates/shirabe/src/plugin/plugin_manager.rs
+++ b/crates/shirabe/src/plugin/plugin_manager.rs
@@ -4,15 +4,6 @@
//! and is not implemented in Phase A. The structure is mirrored verbatim so
//! future plugin support can fill in the runtime hooks.
-use indexmap::IndexMap;
-
-use shirabe_external_packages::composer::pcre::Preg;
-use shirabe_php_shim::{
- E_USER_DEPRECATED, PhpMixed, RuntimeException, UnexpectedValueException, array_key_exists,
- get_class_obj, implode, ksort, trigger_error, trim, var_export_str, version_compare,
-};
-use shirabe_semver::constraint::SimpleConstraint;
-
use crate::composer::PartialComposerHandle;
use crate::composer::{ComposerHandle, ComposerWeakHandle};
use crate::factory::DisablePlugins;
@@ -31,6 +22,13 @@ use crate::repository::InstalledRepository;
use crate::repository::RepositoryInterface;
use crate::repository::RepositoryUtils;
use crate::util::PackageSorter;
+use indexmap::IndexMap;
+use shirabe_external_packages::composer::pcre::Preg;
+use shirabe_php_shim::{
+ E_USER_DEPRECATED, PhpMixed, RuntimeException, UnexpectedValueException, array_key_exists,
+ get_class_obj, implode, ksort, trigger_error, trim, var_export_str, version_compare,
+};
+use shirabe_semver::constraint::SimpleConstraint;
#[derive(Debug)]
pub struct PluginManager {
diff --git a/crates/shirabe/src/plugin/post_file_download_event.rs b/crates/shirabe/src/plugin/post_file_download_event.rs
index 9ba946e..88fc181 100644
--- a/crates/shirabe/src/plugin/post_file_download_event.rs
+++ b/crates/shirabe/src/plugin/post_file_download_event.rs
@@ -1,10 +1,9 @@
//! ref: composer/src/Composer/Plugin/PostFileDownloadEvent.php
-use indexmap::IndexMap;
-use shirabe_php_shim::PhpMixed;
-
use crate::event_dispatcher::Event;
use crate::event_dispatcher::EventInterface;
+use indexmap::IndexMap;
+use shirabe_php_shim::PhpMixed;
#[derive(Debug)]
pub struct PostFileDownloadEvent {
diff --git a/crates/shirabe/src/plugin/pre_file_download_event.rs b/crates/shirabe/src/plugin/pre_file_download_event.rs
index 0cd14d7..9ec74a0 100644
--- a/crates/shirabe/src/plugin/pre_file_download_event.rs
+++ b/crates/shirabe/src/plugin/pre_file_download_event.rs
@@ -1,11 +1,10 @@
//! ref: composer/src/Composer/Plugin/PreFileDownloadEvent.php
-use indexmap::IndexMap;
-use shirabe_php_shim::PhpMixed;
-
use crate::event_dispatcher::Event;
use crate::event_dispatcher::EventInterface;
use crate::util::HttpDownloader;
+use indexmap::IndexMap;
+use shirabe_php_shim::PhpMixed;
#[derive(Debug)]
pub struct PreFileDownloadEvent {
diff --git a/crates/shirabe/src/plugin/pre_pool_create_event.rs b/crates/shirabe/src/plugin/pre_pool_create_event.rs
index 303159a..0ffde94 100644
--- a/crates/shirabe/src/plugin/pre_pool_create_event.rs
+++ b/crates/shirabe/src/plugin/pre_pool_create_event.rs
@@ -1,14 +1,12 @@
//! ref: composer/src/Composer/Plugin/PrePoolCreateEvent.php
-use indexmap::IndexMap;
-
-use shirabe_php_shim::PhpMixed;
-
use crate::dependency_resolver::Request;
use crate::event_dispatcher::Event;
use crate::event_dispatcher::EventInterface;
use crate::package::BasePackageHandle;
use crate::repository::RepositoryInterface;
+use indexmap::IndexMap;
+use shirabe_php_shim::PhpMixed;
#[derive(Debug)]
pub struct PrePoolCreateEvent {