summaryrefslogtreecommitdiff
path: root/templates/system/time-zone/node.def
blob: 00da0133ab3463c2158533768797f426a469e03d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
type: txt
help: "Configure local timezone"
default: "GMT"
update: "LTF=\"/usr/share/zoneinfo\" && \
case \"$(@)\" in \
  [Ll][Oo][Ss]*) LTF=\"\\\$LTF/US/Pacific\" ;; \
  [Dd][Ee][Nn]*) LTF=\"\\\$LTF/US/Mountain\" ;; \
  [Hh][Oo][Nn]*) LTF=\"\\\$LTF/US/Hawaii\" ;; \
  [Nn][Ee][Ww]*) LTF=\"\\\$LTF/US/Eastern\" ;; \
  [Cc][Hh][Ii]*) LTF=\"\\\$LTF/US/Central\" ;; \
  [Aa][Nn][Cc]*) LTF=\"\\\$LTF/US/Alaska\" ;; \
  [Pp][Hh][Oo]*) LTF=\"\\\$LTF/US/Arizona\" ;; \
  *) LTF=\"\\\$LTF/Etc/$(@)\" ;; \
esac && \
ln -fs \\\$LTF /etc/localtime"
delete: "ln -fs /usr/share/zoneinfo/GMT /etc/localtime"