quick-links-rofi 0.1.2

A rust program to launch a rofi menu with a bunch of links
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use clap::Parser;
use quick_links_rofi::{
    cli::Cli,
    config::get_configuration,
    input::Items,
    link::{launch_link, launch_rofi},
};

fn main() -> anyhow::Result<()> {
    let cli = Cli::parse();
    let config = cli.update_config(get_configuration()?);

    let items = Items::try_from(config.input_file.as_str())?;
    match launch_rofi(&items, &config)? {
        None => Ok(()),
        Some(s) => launch_link(&s, &items, &config),
    }
}