Crates.io | vt |
lib.rs | vt |
version | 0.2.1 |
source | src |
created_at | 2019-09-04 15:43:30.838552 |
updated_at | 2019-09-10 23:18:33.05732 |
description | Rust bindings for Linux virtual terminal APIs. |
homepage | https://github.com/95ulisse/vt-rs |
repository | https://github.com/95ulisse/vt-rs |
max_upload_size | |
id | 162168 |
size | 25,009 |
Rust bindings for the Linux virtual terminal APIs.
Documentation: https://docs.rs/vt
use std::io::Write;
use vt::Console;
// First of all, get a handle to the console
let console = Console::open().unwrap();
// Allocate a new virtual terminal
let mut vt = console.new_vt().unwrap();
// Write something to it.
// A `Vt` structure implements both `std::io::Read` and `std::io::Write`.
writeln!(vt, "Hello world!");
// Switch to the newly allocated terminal
vt.switch().unwrap();
vt-rs
is released under the MIT license. For more information, see LICENSE.