diff options
| author | Arne Dußin | 2021-01-08 15:57:52 +0100 |
|---|---|---|
| committer | Arne Dußin | 2021-01-08 15:57:52 +0100 |
| commit | 60327dd3ef85a263173e6275cb122c9191c030fe (patch) | |
| tree | 670c2729ade91daadee62dae37faa828ab70b3f4 /src/cli/cmd/mod.rs | |
| parent | d8123704ea4fe4f1fb677db31ecac53c9c40096e (diff) | |
| download | graf_karto-60327dd3ef85a263173e6275cb122c9191c030fe.tar.gz graf_karto-60327dd3ef85a263173e6275cb122c9191c030fe.zip | |
Rename save to write for vim mnemonics compatibility
Diffstat (limited to 'src/cli/cmd/mod.rs')
| -rw-r--r-- | src/cli/cmd/mod.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cli/cmd/mod.rs b/src/cli/cmd/mod.rs index 42e865a..e00b895 100644 --- a/src/cli/cmd/mod.rs +++ b/src/cli/cmd/mod.rs @@ -2,11 +2,11 @@ pub mod edit; pub mod read; -pub mod save; +pub mod write; pub use edit::*; pub use read::*; -pub use save::*; +pub use write::*; use crate::Editor; use std::ops::RangeInclusive; @@ -35,7 +35,7 @@ pub fn parse_command(string: &str) -> Result<Box<dyn Command>, CmdParseError> { let parts: Vec<&str> = string.split_whitespace().collect(); match parts[0] { - "w" => Ok(Box::new(Save::from_args(&parts[1..])?)), + "w" => Ok(Box::new(Write::from_args(&parts[1..])?)), "e" => Ok(Box::new(Edit::from_args(&parts[1..])?)), "r" => Ok(Box::new(Read::from_args(&parts[1..])?)), other => Err(CmdParseError::NoSuchCmd(other.to_owned())), |
