From 769ee04d8bdfb1ce839bb366f169e5f01577aa37 Mon Sep 17 00:00:00 2001 From: ange Date: Wed, 23 Oct 2024 12:22:08 +0700 Subject: [PATCH] feat: updatetz --- .local/bin/ddev | 4 ++-- .local/bin/updatetz | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) create mode 100755 .local/bin/updatetz diff --git a/.local/bin/ddev b/.local/bin/ddev index c94cd96..61ea561 100755 --- a/.local/bin/ddev +++ b/.local/bin/ddev @@ -10,7 +10,7 @@ if [ -z "$1" ]; then exit 1 fi -img="${aliases[$1]:-$1:latest}" +img="${aliases[$1]:-$1:latest}"; shift set -x -podman run --rm -it -v "$PWD:/mnt/" -w /mnt/ "docker.io/$img" +podman run --rm -it -v "$PWD:/mnt/" -w /mnt/ "docker.io/$img" "$@" diff --git a/.local/bin/updatetz b/.local/bin/updatetz new file mode 100755 index 0000000..6126d84 --- /dev/null +++ b/.local/bin/updatetz @@ -0,0 +1,6 @@ +#!/bin/bash -e + +tz="$(curl -Ssf https://ipapi.co/timezone)" + +sudo timedatectl set-timezone "$tz" +echo "$tz"