diff options
author | Dave Reisner <dreisner@archlinux.org> | 2011-09-24 19:43:39 -0400 |
---|---|---|
committer | Dave Reisner <dreisner@archlinux.org> | 2011-09-24 19:43:39 -0400 |
commit | 21f1a7c7eb961c5049fa6d05f95361bdad245dc9 (patch) | |
tree | 4b0c796871e467650d7ca1ccf5fff639a77964b2 /functions | |
parent | 71fe1590598381588502e58b60622b0b72d79454 (diff) |
respect the user's choice for /etc/localtime
This can be a symlink or a regular file, and rc.sysinit will preserve it
as such.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Diffstat (limited to 'functions')
-rw-r--r-- | functions | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -397,7 +397,12 @@ set_timezone() { return 0 fi - ln -sf "/usr/share/zoneinfo/$tz" /etc/localtime + # respect the user's decision to symlink or copy + if [[ -L /etc/localtime ]]; then + ln -sf "/usr/share/zoneinfo/$tz" /etc/localtime + else + cp --remove-destination "/usr/share/zoneinfo/$tz" /etc/localtime + fi } # Filesystem functions |