summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorManos Pitsidianakis <el13635@mail.ntua.gr>2020-10-21 17:57:40 +0300
committerManos Pitsidianakis <el13635@mail.ntua.gr>2020-10-21 17:58:30 +0300
commit7b1ab389facee5fd3982ba1dc70a53f7a740824e (patch)
tree49a80d4aac1bc019cb5938e2dce459dadec06a79
parent594a2bd0dd7be8845517f27e480699f4500182fa (diff)
Remove unused plugin interface
-rw-r--r--Cargo.lock45
-rw-r--r--Cargo.toml3
-rw-r--r--src/bin.rs1
-rw-r--r--src/conf.rs7
-rw-r--r--src/state.rs8
5 files changed, 3 insertions, 61 deletions
diff --git a/Cargo.lock b/Cargo.lock
index dbb3f3b8..1daeb54c 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -1064,9 +1064,6 @@ dependencies = [
"pcre2",
"proc-macro2",
"quote 1.0.7",
- "rmp",
- "rmp-serde",
- "rmpv",
"serde",
"serde_derive",
"serde_json",
@@ -1606,39 +1603,6 @@ dependencies = [
]
[[package]]
-name = "rmp"
-version = "0.8.9"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0f10b46df14cf1ee1ac7baa4d2fbc2c52c0622a4b82fa8740e37bc452ac0184f"
-dependencies = [
- "byteorder",
- "num-traits",
-]
-
-[[package]]
-name = "rmp-serde"
-version = "0.14.4"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4ce7d70c926fe472aed493b902010bccc17fa9f7284145cb8772fd22fdb052d8"
-dependencies = [
- "byteorder",
- "rmp",
- "serde",
-]
-
-[[package]]
-name = "rmpv"
-version = "0.4.5"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ee358f3c4be83ab373cd3e501dc04881034f1ae198e73b2d9edd617653ac4293"
-dependencies = [
- "num-traits",
- "rmp",
- "serde",
- "serde_bytes",
-]
-
-[[package]]
name = "rusqlite"
version = "0.24.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -1729,15 +1693,6 @@ dependencies = [
]
[[package]]
-name = "serde_bytes"
-version = "0.11.5"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "16ae07dd2f88a366f15bd0632ba725227018c69a1c8550a927324f8eb8368bb9"
-dependencies = [
- "serde",
-]
-
-[[package]]
name = "serde_derive"
version = "1.0.116"
source = "registry+https://github.com/rust-lang/crates.io-index"
diff --git a/Cargo.toml b/Cargo.toml
index 1e73817a..78cb35a4 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -46,9 +46,6 @@ bincode = "1.2.0"
uuid = { version = "0.8.1", features = ["serde", "v4"] }
unicode-segmentation = "1.2.1" # >:c
libc = {version = "0.2.59", features = ["extra_traits",]}
-rmp = "^0.8"
-rmpv = { version = "^0.4.2", features=["with-serde",] }
-rmp-serde = "^0.14.0"
smallvec = { version = "^1.4.0", features = ["serde", ] }
bitflags = "1.0"
pcre2 = { version = "0.2.3", optional = true }
diff --git a/src/bin.rs b/src/bin.rs
index a6a9f125..457fe5ab 100644
--- a/src/bin.rs
+++ b/src/bin.rs
@@ -79,7 +79,6 @@ pub mod sqlite3;
pub mod jobs;
pub mod mailcap;
-pub mod plugins;
use std::os::raw::c_int;
diff --git a/src/conf.rs b/src/conf.rs
index ac1fa1bc..7cb50308 100644
--- a/src/conf.rs
+++ b/src/conf.rs
@@ -56,7 +56,6 @@ use self::listing::ListingSettings;
use self::notifications::NotificationsSettings;
use self::terminal::TerminalSettings;
use crate::pager::PagerSettings;
-use crate::plugins::Plugin;
use melib::conf::{AccountSettings, MailboxConf, ToggleFlag};
use melib::error::*;
@@ -212,8 +211,6 @@ pub struct FileSettings {
#[serde(default)]
pub terminal: TerminalSettings,
#[serde(default)]
- pub plugins: IndexMap<String, Plugin>,
- #[serde(default)]
pub log: LogSettings,
}
@@ -432,7 +429,6 @@ pub struct Settings {
pub composing: ComposingSettings,
pub pgp: PGPSettings,
pub terminal: TerminalSettings,
- pub plugins: IndexMap<String, Plugin>,
pub log: LogSettings,
}
@@ -465,7 +461,6 @@ impl Settings {
composing: fs.composing,
pgp: fs.pgp,
terminal: fs.terminal,
- plugins: fs.plugins,
log: fs.log,
})
}
@@ -489,7 +484,6 @@ impl Settings {
composing: fs.composing,
pgp: fs.pgp,
terminal: fs.terminal,
- plugins: fs.plugins,
log: fs.log,
})
}
@@ -901,7 +895,6 @@ mod dotaddressable {
"composing" => Err(MeliError::new("unimplemented")),
"pgp" => Err(MeliError::new("unimplemented")),
"terminal" => self.terminal.lookup(field, tail),
- "plugins" => Err(MeliError::new("unimplemented")),
"log" => self.log.lookup(field, tail),
other => Err(MeliError::new(format!(
diff --git a/src/state.rs b/src/state.rs
index b6cc736b..ce2396d2 100644
--- a/src/state.rs
+++ b/src/state.rs
@@ -29,7 +29,7 @@ Input is received in the main loop from threads which listen on the stdin for us
*/
use super::*;
-use crate::plugins::PluginManager;
+//use crate::plugins::PluginManager;
use melib::backends::{AccountHash, BackendEventConsumer};
use crate::jobs::JobExecutor;
@@ -115,7 +115,6 @@ pub struct Context {
input_thread: InputHandler,
pub job_executor: Arc<JobExecutor>,
pub children: Vec<std::process::Child>,
- pub plugin_manager: PluginManager,
pub temp_files: Vec<File>,
}
@@ -243,9 +242,9 @@ impl State {
} else {
Settings::new()?
};
+ /*
let mut plugin_manager = PluginManager::new();
for (_, p) in settings.plugins.clone() {
- /*
if crate::plugins::PluginKind::Backend == p.kind() {
debug!("registering {:?}", &p);
crate::plugins::backend::PluginBackend::register(
@@ -254,9 +253,9 @@ impl State {
&mut backends,
);
}
- */
plugin_manager.register(p)?;
}
+ */
let termsize = termion::terminal_size()?;
let cols = termsize.0 as usize;
@@ -350,7 +349,6 @@ impl State {
temp_files: Vec::new(),
job_executor,
children: vec![],
- plugin_manager,
input_thread: InputHandler {
pipe: input_thread_pipe,