mirror of
https://github.com/youwen5/iamb.git
synced 2025-06-20 05:39:52 -07:00
Pull in modalkit repository with a Cargo.lock
(#208)
This commit is contained in:
parent
aa878f7569
commit
c5999bffc8
12 changed files with 76 additions and 100 deletions
6
Cargo.lock
generated
6
Cargo.lock
generated
|
@ -1862,7 +1862,7 @@ dependencies = [
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "keybindings"
|
name = "keybindings"
|
||||||
version = "0.0.1"
|
version = "0.0.1"
|
||||||
source = "git+https://github.com/ulyssa/modalkit?rev=5ebcaf1#5ebcaf18289526216a4e852a6c2c9ee03709e717"
|
source = "git+https://github.com/ulyssa/modalkit?rev=cb8c8aeb9a499b9b16615ce144f9014d78036e01#cb8c8aeb9a499b9b16615ce144f9014d78036e01"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"textwrap",
|
"textwrap",
|
||||||
"unicode-segmentation",
|
"unicode-segmentation",
|
||||||
|
@ -2255,7 +2255,7 @@ dependencies = [
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "modalkit"
|
name = "modalkit"
|
||||||
version = "0.0.17"
|
version = "0.0.17"
|
||||||
source = "git+https://github.com/ulyssa/modalkit?rev=5ebcaf1#5ebcaf18289526216a4e852a6c2c9ee03709e717"
|
source = "git+https://github.com/ulyssa/modalkit?rev=cb8c8aeb9a499b9b16615ce144f9014d78036e01#cb8c8aeb9a499b9b16615ce144f9014d78036e01"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anymap2",
|
"anymap2",
|
||||||
"arboard",
|
"arboard",
|
||||||
|
@ -2276,7 +2276,7 @@ dependencies = [
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "modalkit-ratatui"
|
name = "modalkit-ratatui"
|
||||||
version = "0.0.17"
|
version = "0.0.17"
|
||||||
source = "git+https://github.com/ulyssa/modalkit?rev=5ebcaf1#5ebcaf18289526216a4e852a6c2c9ee03709e717"
|
source = "git+https://github.com/ulyssa/modalkit?rev=cb8c8aeb9a499b9b16615ce144f9014d78036e01#cb8c8aeb9a499b9b16615ce144f9014d78036e01"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"crossterm 0.27.0",
|
"crossterm 0.27.0",
|
||||||
"intervaltree",
|
"intervaltree",
|
||||||
|
|
|
@ -58,12 +58,12 @@ edit = "0.1.4"
|
||||||
[dependencies.modalkit]
|
[dependencies.modalkit]
|
||||||
version = "0.0.17"
|
version = "0.0.17"
|
||||||
git = "https://github.com/ulyssa/modalkit"
|
git = "https://github.com/ulyssa/modalkit"
|
||||||
rev = "5ebcaf1"
|
rev = "cb8c8aeb9a499b9b16615ce144f9014d78036e01"
|
||||||
|
|
||||||
[dependencies.modalkit-ratatui]
|
[dependencies.modalkit-ratatui]
|
||||||
version = "0.0.17"
|
version = "0.0.17"
|
||||||
git = "https://github.com/ulyssa/modalkit"
|
git = "https://github.com/ulyssa/modalkit"
|
||||||
rev = "5ebcaf1"
|
rev = "cb8c8aeb9a499b9b16615ce144f9014d78036e01"
|
||||||
|
|
||||||
[dependencies.matrix-sdk]
|
[dependencies.matrix-sdk]
|
||||||
version = "^0.6.2"
|
version = "^0.6.2"
|
||||||
|
|
|
@ -58,8 +58,8 @@ use matrix_sdk::{
|
||||||
};
|
};
|
||||||
|
|
||||||
use modalkit::{
|
use modalkit::{
|
||||||
|
actions::Action,
|
||||||
editing::{
|
editing::{
|
||||||
action::{Action, UIError, UIResult},
|
|
||||||
application::{
|
application::{
|
||||||
ApplicationAction,
|
ApplicationAction,
|
||||||
ApplicationContentId,
|
ApplicationContentId,
|
||||||
|
@ -78,6 +78,7 @@ use modalkit::{
|
||||||
command::{CommandContext, CommandDescription, VimCommand, VimCommandMachine},
|
command::{CommandContext, CommandDescription, VimCommand, VimCommandMachine},
|
||||||
keybindings::VimMachine,
|
keybindings::VimMachine,
|
||||||
},
|
},
|
||||||
|
errors::{UIError, UIResult},
|
||||||
key::TerminalKey,
|
key::TerminalKey,
|
||||||
keybindings::SequenceStatus,
|
keybindings::SequenceStatus,
|
||||||
prelude::{CommandType, WordStyle},
|
prelude::{CommandType, WordStyle},
|
||||||
|
|
|
@ -604,7 +604,7 @@ pub fn setup_commands() -> ProgramCommands {
|
||||||
mod tests {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
use matrix_sdk::ruma::user_id;
|
use matrix_sdk::ruma::user_id;
|
||||||
use modalkit::editing::action::WindowAction;
|
use modalkit::actions::WindowAction;
|
||||||
use modalkit::editing::context::EditContext;
|
use modalkit::editing::context::EditContext;
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
//! The keybindings are set up here. We define some iamb-specific keybindings, but the default Vim
|
//! The keybindings are set up here. We define some iamb-specific keybindings, but the default Vim
|
||||||
//! keys come from [modalkit::env::vim::keybindings].
|
//! keys come from [modalkit::env::vim::keybindings].
|
||||||
use modalkit::{
|
use modalkit::{
|
||||||
editing::action::WindowAction,
|
actions::WindowAction,
|
||||||
env::vim::keybindings::{InputStep, VimBindings},
|
env::vim::keybindings::{InputStep, VimBindings},
|
||||||
env::vim::VimMode,
|
env::vim::VimMode,
|
||||||
key::TerminalKey,
|
key::TerminalKey,
|
||||||
|
|
13
src/main.rs
13
src/main.rs
|
@ -89,15 +89,11 @@ use crate::{
|
||||||
};
|
};
|
||||||
|
|
||||||
use modalkit::{
|
use modalkit::{
|
||||||
editing::{
|
actions::{
|
||||||
action::{
|
|
||||||
Action,
|
Action,
|
||||||
Commandable,
|
Commandable,
|
||||||
EditError,
|
|
||||||
EditInfo,
|
|
||||||
Editable,
|
Editable,
|
||||||
EditorAction,
|
EditorAction,
|
||||||
InfoMessage,
|
|
||||||
InsertTextAction,
|
InsertTextAction,
|
||||||
Jumpable,
|
Jumpable,
|
||||||
Promptable,
|
Promptable,
|
||||||
|
@ -105,14 +101,11 @@ use modalkit::{
|
||||||
TabAction,
|
TabAction,
|
||||||
TabContainer,
|
TabContainer,
|
||||||
TabCount,
|
TabCount,
|
||||||
UIError,
|
|
||||||
WindowAction,
|
WindowAction,
|
||||||
WindowContainer,
|
WindowContainer,
|
||||||
},
|
},
|
||||||
context::Resolve,
|
editing::{context::Resolve, key::KeyManager, store::Store},
|
||||||
key::KeyManager,
|
errors::{EditError, UIError},
|
||||||
store::Store,
|
|
||||||
},
|
|
||||||
key::TerminalKey,
|
key::TerminalKey,
|
||||||
keybindings::{
|
keybindings::{
|
||||||
dialog::{Pager, PromptYesNo},
|
dialog::{Pager, PromptYesNo},
|
||||||
|
|
|
@ -33,23 +33,18 @@ use ratatui::{
|
||||||
};
|
};
|
||||||
|
|
||||||
use modalkit::{
|
use modalkit::{
|
||||||
editing::{
|
actions::{
|
||||||
action::{
|
|
||||||
Action,
|
Action,
|
||||||
EditError,
|
|
||||||
EditInfo,
|
|
||||||
EditResult,
|
|
||||||
Editable,
|
Editable,
|
||||||
EditorAction,
|
EditorAction,
|
||||||
Jumpable,
|
Jumpable,
|
||||||
PromptAction,
|
PromptAction,
|
||||||
Promptable,
|
Promptable,
|
||||||
Scrollable,
|
Scrollable,
|
||||||
UIError,
|
|
||||||
WindowAction,
|
WindowAction,
|
||||||
},
|
},
|
||||||
completion::CompletionList,
|
editing::completion::CompletionList,
|
||||||
},
|
errors::{EditError, EditResult, UIError},
|
||||||
prelude::*,
|
prelude::*,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -47,26 +47,22 @@ use modalkit_ratatui::{
|
||||||
WindowOps,
|
WindowOps,
|
||||||
};
|
};
|
||||||
|
|
||||||
use modalkit::editing::{
|
use modalkit::actions::{
|
||||||
action::{
|
|
||||||
Action,
|
Action,
|
||||||
EditError,
|
|
||||||
EditInfo,
|
|
||||||
EditResult,
|
|
||||||
Editable,
|
Editable,
|
||||||
EditorAction,
|
EditorAction,
|
||||||
InfoMessage,
|
|
||||||
Jumpable,
|
Jumpable,
|
||||||
PromptAction,
|
PromptAction,
|
||||||
Promptable,
|
Promptable,
|
||||||
Scrollable,
|
Scrollable,
|
||||||
UIError,
|
};
|
||||||
},
|
use modalkit::editing::{
|
||||||
completion::CompletionList,
|
completion::CompletionList,
|
||||||
context::Resolve,
|
context::Resolve,
|
||||||
history::{self, HistoryList},
|
history::{self, HistoryList},
|
||||||
rope::EditRope,
|
rope::EditRope,
|
||||||
};
|
};
|
||||||
|
use modalkit::errors::{EditError, EditResult, UIError};
|
||||||
use modalkit::prelude::*;
|
use modalkit::prelude::*;
|
||||||
|
|
||||||
use crate::base::{
|
use crate::base::{
|
||||||
|
|
|
@ -19,23 +19,18 @@ use ratatui::{
|
||||||
widgets::{Paragraph, StatefulWidget, Widget},
|
widgets::{Paragraph, StatefulWidget, Widget},
|
||||||
};
|
};
|
||||||
|
|
||||||
use modalkit::prelude::*;
|
use modalkit::actions::{
|
||||||
use modalkit::{
|
|
||||||
editing::action::{
|
|
||||||
Action,
|
Action,
|
||||||
EditInfo,
|
|
||||||
EditResult,
|
|
||||||
Editable,
|
Editable,
|
||||||
EditorAction,
|
EditorAction,
|
||||||
Jumpable,
|
Jumpable,
|
||||||
PromptAction,
|
PromptAction,
|
||||||
Promptable,
|
Promptable,
|
||||||
Scrollable,
|
Scrollable,
|
||||||
UIError,
|
|
||||||
},
|
|
||||||
editing::completion::CompletionList,
|
|
||||||
keybindings::dialog::PromptYesNo,
|
|
||||||
};
|
};
|
||||||
|
use modalkit::errors::{EditResult, UIError};
|
||||||
|
use modalkit::prelude::*;
|
||||||
|
use modalkit::{editing::completion::CompletionList, keybindings::dialog::PromptYesNo};
|
||||||
use modalkit_ratatui::{TermOffset, TerminalCursor, WindowOps};
|
use modalkit_ratatui::{TermOffset, TerminalCursor, WindowOps};
|
||||||
|
|
||||||
use crate::base::{
|
use crate::base::{
|
||||||
|
|
|
@ -14,14 +14,10 @@ use ratatui::{
|
||||||
widgets::{Paragraph, StatefulWidget, Widget},
|
widgets::{Paragraph, StatefulWidget, Widget},
|
||||||
};
|
};
|
||||||
|
|
||||||
use modalkit::editing::{
|
use modalkit::actions::{
|
||||||
action::{
|
|
||||||
Action,
|
Action,
|
||||||
CursorAction,
|
CursorAction,
|
||||||
EditAction,
|
EditAction,
|
||||||
EditError,
|
|
||||||
EditInfo,
|
|
||||||
EditResult,
|
|
||||||
Editable,
|
Editable,
|
||||||
EditorAction,
|
EditorAction,
|
||||||
EditorActions,
|
EditorActions,
|
||||||
|
@ -33,9 +29,8 @@ use modalkit::editing::{
|
||||||
Scrollable,
|
Scrollable,
|
||||||
Searchable,
|
Searchable,
|
||||||
SelectionAction,
|
SelectionAction,
|
||||||
UIError,
|
};
|
||||||
UIResult,
|
use modalkit::editing::{
|
||||||
},
|
|
||||||
completion::CompletionList,
|
completion::CompletionList,
|
||||||
context::Resolve,
|
context::Resolve,
|
||||||
cursor::{CursorGroup, CursorState},
|
cursor::{CursorGroup, CursorState},
|
||||||
|
@ -43,6 +38,7 @@ use modalkit::editing::{
|
||||||
rope::EditRope,
|
rope::EditRope,
|
||||||
store::{RegisterCell, RegisterPutFlags},
|
store::{RegisterCell, RegisterPutFlags},
|
||||||
};
|
};
|
||||||
|
use modalkit::errors::{EditError, EditResult, UIError, UIResult};
|
||||||
use modalkit::prelude::*;
|
use modalkit::prelude::*;
|
||||||
|
|
||||||
use crate::{
|
use crate::{
|
||||||
|
|
|
@ -5,7 +5,6 @@ use ratatui::{buffer::Buffer, layout::Rect};
|
||||||
|
|
||||||
use modalkit_ratatui::{textbox::TextBoxState, TermOffset, TerminalCursor, WindowOps};
|
use modalkit_ratatui::{textbox::TextBoxState, TermOffset, TerminalCursor, WindowOps};
|
||||||
|
|
||||||
use modalkit::editing::action::EditInfo;
|
|
||||||
use modalkit::editing::completion::CompletionList;
|
use modalkit::editing::completion::CompletionList;
|
||||||
use modalkit::prelude::*;
|
use modalkit::prelude::*;
|
||||||
|
|
||||||
|
|
|
@ -77,7 +77,8 @@ use matrix_sdk::{
|
||||||
Session,
|
Session,
|
||||||
};
|
};
|
||||||
|
|
||||||
use modalkit::editing::action::{EditInfo, InfoMessage, UIError};
|
use modalkit::errors::UIError;
|
||||||
|
use modalkit::prelude::{EditInfo, InfoMessage};
|
||||||
|
|
||||||
use crate::base::Need;
|
use crate::base::Need;
|
||||||
use crate::{
|
use crate::{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue