diff options
Diffstat (limited to 'bin/events2semesterplan.pl')
-rwxr-xr-x | bin/events2semesterplan.pl | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/bin/events2semesterplan.pl b/bin/events2semesterplan.pl index 9d20957..2df85ad 100755 --- a/bin/events2semesterplan.pl +++ b/bin/events2semesterplan.pl @@ -32,6 +32,7 @@ use Text::Xslate; use POSIX qw(locale_h); # resolve LC_TIME use locale; use DateTime::TimeZone; +use LaTeX::Encode qw(latex_encode); use LaTeX::Driver; use Object::Groupware::DAV; @@ -148,10 +149,13 @@ my @events = $calendar->events($span); my %vars; #$vars{metadata} = $calendar->metadata(); -$vars{name} = $ARGS{title} || ''; +$vars{name} = latex_encode( $ARGS{title} ) || ''; for (@events) { next unless $_->summary; - push @{ $vars{events} }, $_; + push @{ $vars{events} }, { + start_date => $_->start_date, + summary => latex_encode( $_->summary ), + }; } my %tmpl; |