2
0
mirror of https://github.com/xvxx/phetch synced 2024-11-12 13:10:40 +00:00
phetch/src/ui/mode.rs

18 lines
407 B
Rust
Raw Normal View History

2020-01-11 23:50:25 +00:00
/// The mode our text UI is in. Run mode is the default while
2020-01-12 02:15:07 +00:00
/// Print doesn't show the cursor, among other things.
2020-01-11 23:50:25 +00:00
#[derive(Debug, PartialEq, Copy, Clone)]
pub enum Mode {
2020-01-12 02:15:07 +00:00
Run, // url
Print, // --print url
NoTTY, // --print url | cat
Raw, // --raw
Version, // --version
Help, // --help
2020-01-11 23:50:25 +00:00
}
impl Default for Mode {
fn default() -> Self {
Mode::Run
}
}