From 952f2e5b2256a4535c43bebccef099dc91a3c0db Mon Sep 17 00:00:00 2001 From: Andrew Titmuss Date: Fri, 13 Oct 2017 14:24:56 +1100 Subject: [PATCH 1/3] fix Install Date for macOS --- neofetch | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/neofetch b/neofetch index 0ce2959d..2614c123 100755 --- a/neofetch +++ b/neofetch @@ -2254,7 +2254,13 @@ get_install_date() { return ;; - *) install_date="$(ls -dlctT "$install_file" | awk '{printf $9 " " $6 " "$7 " " $8}')" ;; + *) + if [[ "$os" == "Mac OS X" ]]; then + install_date="$(ls -dlctuT "$install_file" | awk '{printf $9 " " $6 " " $7 " " $8}')" + else + install_date="$(ls -dlctT "$install_file" | awk '{printf $9 " " $6 " " $7 " " $8}')" + fi + ;; esac install_date="${install_date//-/ }" From 3cac29c804d763352db07e37a996e474d2719240 Mon Sep 17 00:00:00 2001 From: Andrew Titmuss Date: Fri, 13 Oct 2017 14:32:58 +1100 Subject: [PATCH 2/3] Change -u to -U in macOS install date --- neofetch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/neofetch b/neofetch index 2614c123..f578ba7c 100755 --- a/neofetch +++ b/neofetch @@ -2256,7 +2256,7 @@ get_install_date() { *) if [[ "$os" == "Mac OS X" ]]; then - install_date="$(ls -dlctuT "$install_file" | awk '{printf $9 " " $6 " " $7 " " $8}')" + install_date="$(ls -dlctUT "$install_file" | awk '{printf $9 " " $6 " " $7 " " $8}')" else install_date="$(ls -dlctT "$install_file" | awk '{printf $9 " " $6 " " $7 " " $8}')" fi From 123d1652ff0549505acb1f30abbc7d37b7ccb3f1 Mon Sep 17 00:00:00 2001 From: Andrew Titmuss Date: Fri, 13 Oct 2017 14:44:22 +1100 Subject: [PATCH 3/3] fix line length to be under 100 chars in macOS install date --- neofetch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/neofetch b/neofetch index f578ba7c..2636d8ed 100755 --- a/neofetch +++ b/neofetch @@ -2256,7 +2256,7 @@ get_install_date() { *) if [[ "$os" == "Mac OS X" ]]; then - install_date="$(ls -dlctUT "$install_file" | awk '{printf $9 " " $6 " " $7 " " $8}')" + install_date="$(ls -dlctUT "$install_file" | awk '{printf $9 " " $6 " "$7 " " $8}')" else install_date="$(ls -dlctT "$install_file" | awk '{printf $9 " " $6 " " $7 " " $8}')" fi