20 lines
337 B
Rust
20 lines
337 B
Rust
mod editor;
|
|
mod helpers;
|
|
|
|
use crate::editor::Editor;
|
|
use crate::helpers::*;
|
|
|
|
fn main() {
|
|
let original_termios = get_termios(STDIN_FILENO);
|
|
|
|
enable_raw_mode().unwrap();
|
|
|
|
let mut editor = Editor::new();
|
|
|
|
while editor.process_keypress().is_some() {
|
|
// loop
|
|
}
|
|
|
|
disable_raw_mode(&original_termios).unwrap();
|
|
}
|