Some initial work on a better repl

This commit is contained in:
greg 2019-02-10 01:00:40 -08:00
parent be90a859db
commit 93e96acc66
2 changed files with 15 additions and 0 deletions

View File

@ -23,6 +23,7 @@ use std::io::Read;
use std::process::exit; use std::process::exit;
use std::default::Default; use std::default::Default;
mod new_repl;
mod repl; mod repl;
mod language; mod language;
mod webapp; mod webapp;
@ -82,8 +83,11 @@ pub fn repl_main(generators: Vec<PLIGenerator>) {
match option_matches.free[..] { match option_matches.free[..] {
[] | [_] => { [] | [_] => {
/*
let mut repl = repl::Repl::new(languages, initial_index); let mut repl = repl::Repl::new(languages, initial_index);
repl.run(); repl.run();
*/
new_repl::run();
} }
[_, ref filename, _..] => { [_, ref filename, _..] => {

View File

@ -0,0 +1,11 @@
use cursive::Cursive;
use cursive::views::{Dialog, TextView};
pub fn run() {
println!("YOLO");
let mut siv = Cursive::default();
siv.add_layer(Dialog::around(TextView::new("FUCKO"))
.title("YOLO SWAGGGGG")
.button("exit", |s| { s.quit() }));
siv.run();
}