From 814481f7606f5284002e78936fa131b3c4f9e764 Mon Sep 17 00:00:00 2001 From: "Daniel (Fourdee)" Date: Mon, 20 Aug 2018 23:06:14 +0100 Subject: [PATCH] v6.14 + Date fix EMR: https://github.com/Fourdee/DietPi/issues/2026#issuecomment-414475011 --- dietpi/func/obtain_network_details | 2 -- dietpi/patch_file | 15 ++++++++++++++- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/dietpi/func/obtain_network_details b/dietpi/func/obtain_network_details index 67c1651ddc..88f0c3040b 100644 --- a/dietpi/func/obtain_network_details +++ b/dietpi/func/obtain_network_details @@ -97,8 +97,6 @@ done - - } #///////////////////////////////////////////////////////////////////////////////////// diff --git a/dietpi/patch_file b/dietpi/patch_file index b7fcd92b2e..10cd5c5ce5 100644 --- a/dietpi/patch_file +++ b/dietpi/patch_file @@ -84,7 +84,20 @@ Update_EMR_Index - # elif (( $EMR_INDEX == 2 )); then + elif (( $EMR_INDEX == 2 )); then + + #Date fix, due to NTP > systemd-timesyncd, unknown cause: https://github.com/Fourdee/DietPi/issues/2017 + if (( $(date +%Y%m) < 201808 )); then + + G_RUN_CMD wget --no-check-certificate https://dietpi.com/downloads/date -O emr2_date_set + date +%Y%m%d -s "$(cat emr2_date_set)" + rm emr2_date_set + + fi + + Update_EMR_Index + + # elif (( $EMR_INDEX == 3 )); then #echo -e 'nothing here yet' # Update_EMR_Index