#!/bin/bash #-------------------------------- # Download: wget https://diii.neocities.org/time.txt # Usage: # chmod +x time.txt # sh time.txt #將系統時鐘設置到硬體時鐘 sudo sh -c "hwclock --systohc" #硬體時間設置成 UTC sudo sh -c "timedatectl set-local-rtc 0" #設定時區 sudo sh -c "ln -sf /usr/share/zoneinfo/Asia/Taipei /etc/localtime" #啟動NTP(Network Time Protocol) sudo sh -c "timedatectl set-ntp true" echo -e "Completed!"