X-Git-Url: https://git.plutz.net/?p=confetti;a=blobdiff_plain;f=categories%2Fl10n.sh;fp=actions%2Fexport_ical.sh;h=c0e64216e48838cb5cc8b2e56ee7b50470910ed8;hp=e595cb68fb9a4d8af629de657f4cf0376bd9ae44;hb=76c1e7bff1a8604ef2ef7da5d274d0db0e639139;hpb=90288ab07bb1ec83a91581fadc674a87a250a853 diff --git a/actions/export_ical.sh b/categories/l10n.sh old mode 100755 new mode 100644 similarity index 63% rename from actions/export_ical.sh rename to categories/l10n.sh index e595cb6..c0e6421 --- a/actions/export_ical.sh +++ b/categories/l10n.sh @@ -1,6 +1,4 @@ -#!/bin/zsh - -# Copyright 2014,2015 Paul Hänsch +# Copyright 2014, 2015, 2016, 2019, 2021 Paul Hänsch # # This file is part of Confetti. # @@ -17,6 +15,16 @@ # You should have received a copy of the GNU Affero General Public License # along with Confetti. If not, see . -echo -n "Content-Type: text/calendar;charset=utf-8\n\n" -course="${_GET[course]}" -cat "$_DATA/ical/$course" +l10n(){ + local word + [ $# -eq 0 ] && read -r word || word="$*" + case $word in + cat_remove) printf %s "-";; + cat_add) printf %s "+";; + cat_newlabel) printf %s "neue Kategorie";; + cat_update) printf %s "Zuweisungen übernehmen";; + categories_label) printf %s "Kategorien";; + + *) l10n_global "$word";; + esac +}