2 releases
Uses old Rust 2015
0.1.1 | Nov 6, 2016 |
---|---|
0.1.0 | Nov 6, 2016 |
#18 in #alfred-workflow
21KB
321 lines
rusty_alfred
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
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