• Stars
    star
    125
  • Rank 286,335 (Top 6 %)
  • Language
    Rust
  • License
    Apache License 2.0
  • Created over 8 years ago
  • Updated 30 days ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

πŸ“† icalendar library, in Rust of course - for fun

iCalendar in Rust

build Crates.io contributors maintenance

version documentation license

A builder [and parser] for rfc5545 iCalendar.

You want to help make this more mature? Please talk to me, Pull Requests and suggestions are very welcome.

Example

Use the builder-pattern to assemble the full calender or event by event. Display printing produces the rfc5545 format.

// lets create a calendar
let my_calendar = Calendar::new()
    .name("example calendar")
    .push(
        // add an event
        Event::new()
            .summary("test event")
            .description("here I have something really important to do")
            .starts(Utc::now())
            .class(Class::Confidential)
            .ends(Utc::now() + Duration::days(1))
            .append_property(
                Property::new("TEST", "FOOBAR")
                    .add_parameter("IMPORTANCE", "very")
                    .add_parameter("DUE", "tomorrow")
                    .done(),
            )
            .done(),
    )
    .push(
        // add a todo
        Todo::new()
            .summary("groceries")
            .description("Buy some milk")
            .done(),
    )
    .push(
        // add an all-day event
        Event::new()
            .all_day(NaiveDate::from_ymd_opt(2016, 3, 15).unwrap())
            .summary("My Birthday")
            .description("Hey, I'm gonna have a party\nBYOB: Bring your own beer.\nHendrik")
            .done(),
    )
    .push(
        // local event with timezone
        Event::new()
            .starts(CalendarDateTime::from_ymd_hm_tzid(2023, 3, 15, 18, 45, Berlin).unwrap())
            .summary("Birthday Party")
            .description("I'm gonna have a party\nBYOB: Bring your own beer.\nHendrik")
            .done(),
    )
    .done();

println!("{}", my_calendar);

Parsing

There is a feature called "parser" which allows you to read calendars again like this:

//... continue from previous example

let parsed_calendar = my_calendar.parse::<Calendar>()?;

License

icalendar-rs is licensed under either of

at your option.

Contribution

Any help in form of descriptive and friendly issues or comprehensive pull requests are welcome!

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in icalendar-rs by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

More Repositories

1

notify-rust

☝️send desktop notifications from your Rust app.
Rust
1,000
star
2

concatenation_benchmarks-rs

πŸ“ˆ benchmarking different ways to concatenate strings in rust
Rust
300
star
3

awesome-rust-testing

😎 Curated list of awesome things regarding Rust Testing
160
star
4

toastify

🍞A commandline tool that shows desktop notifications using notify-rust
Rust
80
star
5

shell-uglify

Uglify Shellcode
Shell
21
star
6

wikitranslate-rs

πŸ“– Use Wikipedia as a dictionary
Rust
8
star
7

bill-rs

πŸ’Έ Tiny little billing library.
Rust
8
star
8

dateparser_benchmarks

πŸ“† comparing nom iso8601, chrono and rust-datetime
Rust
8
star
9

serde-json-schema

WIP json-schema implementation using serde
Rust
8
star
10

rosemary

⏳because we ain't got no thyme
Rust
8
star
11

battery-rs

πŸ”‹ tiny little indicator for your battery status (🐧 linux only)
Rust
6
star
12

fritz.rs

🐭 just me playing around with the fritz.box api
Rust
6
star
13

iterators.ts

πŸ›‹οΈ rustical iterators in typescript
TypeScript
6
star
14

sdp-nom

βš“οΈ i=a wasm friendly SDP parser
Rust
6
star
15

claude-rs

πŸ’Έ oppinionated fork of currency-rs
Rust
5
star
16

magnetoplasmadynamic-thruster

⏏️ Webinterface to MPD
Rust
5
star
17

guardgen

πŸ’‚πŸ»β€β™‚οΈ generate type guards from interface files
TypeScript
5
star
18

xxrb

πŸ€–extensible xmpp ruby bot
Ruby
4
star
19

rust-chess

little try at implementing chess in rust
Rust
3
star
20

dvb-rs

πŸš‹ talking to the dvb api
Rust
3
star
21

scrape

πŸͺš minimal scraping tool for personal use
Rust
3
star
22

webrtc-demo

Little Demonstrator for webrtc
Svelte
2
star
23

dotfiles

my very own dotfiles
Shell
2
star
24

parken-rs

just playing around with scrapers
Rust
2
star
25

signaler

Rust
2
star
26

oslab

my complex lab "operating systems"
C++
2
star
27

hannibal

a small actor library
Rust
2
star
28

old_dotfiles

my dotfiles
Vim Script
2
star
29

treeify-rs

🌳 tiny pretty printer for yaml
Rust
2
star
30

TIL

1
star
31

zutun

a very svelte todo list
HTML
1
star
32

sexy

❀️ the sexiest repo ever
HTML
1
star
33

vim-dojo

notes on a ~60min vim workshop
1
star
34

zummi

πŸ₯„ a criny tate for creating spunny foonerisms
Rust
1
star
35

cpp_feature_tests-rs

@erikzenker's Cpp-Feature-Tests in Rust
Rust
1
star
36

mini-cmb

mini catch my bus example
Rust
1
star
37

notification_osc_bridge

Services for streaming desktop notifications over osc, because!
Rust
1
star
38

hashmusic

little script that searches twitter for #hashmusic and adds the tweets content to mpd
Ruby
1
star
39

awesome-rust-actor-frameworks

πŸ•΄me coping with the amount of actor frameworks out there
1
star
40

dateberry

🌴 sweet little dates
HTML
1
star
41

ferris

lots of cute little crabs
1
star
42

talks

my talks
JavaScript
1
star
43

peerchat

Rust
1
star
44

rust-workshop-chat

πŸ‘¨β€πŸ«πŸ¦€ tiny beginners rust workshop
Rust
1
star
45

rss-cli

a tiny commandline tool to read news, finds rss or atom automatically in html
Ruby
1
star
46

emailaddress-rs

Email Address parsing library for Rust
Rust
1
star
47

sigur_ros

Rust
1
star
48

a-not-so-brief-intro-to-rust

πŸ‘¨β€πŸ«πŸ¦€ Extended version of "A very brief intro to rust" by rustbridge
1
star
49

cast-me

πŸ“½οΈ WS broker
Rust
1
star
50

gutsy

actix based websocket log receiver
Rust
1
star
51

DirCaster

turns any directory on your webserver into a podcast
1
star
52

Chumby-Radiolist-GUI

a tiny interface to modiy the channels on chumby
Python
1
star