hello_world/
hello_world.rs

1use pager_rs::{CommandList, State, StatusBar};
2fn main() -> std::io::Result<()> {
3    let content = r#"fn main() {
4    println!("Hello World!");
5}"#
6    .to_string();
7
8    let status_bar = StatusBar::new("Hello World program in rust".to_string());
9
10    let mut state = State::new(content, status_bar, CommandList::default())?;
11
12    pager_rs::init()?;
13
14    pager_rs::run(&mut state)?;
15
16    pager_rs::finish()?;
17
18    Ok(())
19}