1
0
Fork 0
mirror of https://gitlab.postmarketos.org/postmarketOS/pmaports.git synced 2025-07-25 15:55:11 +03:00
pmaports/extra-repos/systemd/postmarketos-base-systemd/rootfs-usr-bin-setup-timezone
Oliver Smith 06d1177575
extra-repos/systemd/: move from systemd/ (MR 5563)
Let's put everything systemd related in an extra-repos directory, so it
is clear that the packages from here will end up in a separate, optional
binary package repository.
2025-01-10 13:02:31 +01:00

19 lines
524 B
Bash

#!/bin/sh -e
# Stub that implements a simplified version of Alpine's setup-timezone, so
# pmbootstrap can call it during "pmbootstrap install" without having a
# dependency on alpine-conf, which in turn depends on openrc.
if [ "$#" != "2" ] || [ "$1" != "-i" ]; then
echo "setup-timezone stub from postmarketos-base-systemd"
echo "usage: setup-timezone -i TIMEZONE"
exit 1
fi
TZ_FILE="/usr/share/zoneinfo/$2"
if ! [ -e "$TZ_FILE" ]; then
echo "ERROR: not found: $TZ_FILE"
exit 1
fi
ln -sf "$TZ_FILE" /etc/localtime