diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2019-02-08 21:13:08 +0100 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2019-02-08 21:23:31 +0100 |
commit | 8e2d4025fc02e07866869a33ccc686f87389cb36 (patch) | |
tree | 2af14e4713d88024597add14106d565055317cb4 /code.scm | |
parent | Made root of graphviz output gray. (diff) | |
download | calp-8e2d4025fc02e07866869a33ccc686f87389cb36.tar.gz calp-8e2d4025fc02e07866869a33ccc686f87389cb36.tar.xz |
V{calendar,event} merged into vcomponent, making it symmetic.
Diffstat (limited to 'code.scm')
-rwxr-xr-x | code.scm | 29 |
1 files changed, 28 insertions, 1 deletions
@@ -14,4 +14,31 @@ (do ((i 0 (1+ i))) ((>= i (calendar-size v))) (format #t "~3d | ~a~%" - i (calendar-get-attr v i "summary"))) + (1+ i) (car (calendar-get-attr v i "summary")))) + + +;;; ---------------------------------------- + +;; (use-modules (srfi srfi-19)) + +#| +- Z at end means that it's in UTC time. +- No mark at end means that it's in "local time". +- `TZID` can be given as an parameter, specifiying the timezone by name + +See p. 46-47 of the RFC +|# + +;; (string->date (calendar-get-attr v 0 "dtstart") +;; "~Y~m~eT~k~M~S~z") +;; => #<date nanosecond: 0 second: 0 minute: 15 hour: 12 day: 29 month: 1 year: 2019 zone-offset: 0> + +;; (string->date (calendar-get-attr v 0 "dtstart") +;; "~Y~m~eT~k~M~S") +;; => #<date nanosecond: 0 second: 0 minute: 15 hour: 12 day: 29 month: 1 year: 2019 zone-offset: 3600> + +;; (string-take-right (calendar-get-attr v 0 "dtstart") 1) ; => "Z" + +;; (string->date "20180311T133700" +;; "~Y~m~eT~k~M~S") ; <-- Note missing ~z +;; => #<date nanosecond: 0 second: 0 minute: 37 hour: 13 day: 11 month: 3 year: 2018 zone-offset: 3600> |