#alfred #alfred-workflow #workflow

nightly bin+lib rusty_alfred

Interaction with Alfred 3 workflows

2 releases

Uses old Rust 2015

0.1.1 Nov 6, 2016
0.1.0 Nov 6, 2016

#18 in #alfred-workflow

MPL-2.0 license

21KB
321 lines

rusty_alfred

docs

Rusty Alfred is a quick library built to interact with Alfred 3 via Script Filters in the JSON format.

Here's a quick example, but there are more in the bin directory.

extern crate rusty_alfred;

use rusty_alfred::*;

fn main() {
  let items = AlfredItems::new()
    .item(AlfredItem::new("First item")
      .subtitle("The first item's subtitle"))
    .item(AlfredItem::new("Second item")
      .subtitle("Another subtitle!"));
  println!("{}", items.to_json().unwrap());
}

The above example produces example output


lib.rs:

Rusty Alfred is a quick library built to interact with Alfred 3 via Script Filters in the JSON format.

Basic example:

use rusty_alfred::*;

fn main() {
  let items = AlfredItems::new()
    .item(AlfredItem::new("First item")
      .subtitle("The first item's subtitle"))
    .item(AlfredItem::new("Second item")
      .subtitle("Another subtitle!"));
  println!("{}", items.to_json().unwrap());
}

Dependencies

~2.5MB
~57K SLoC