From 435a1e74f1e83cbf6b49ca9e20f77a7e4ddba1b2 Mon Sep 17 00:00:00 2001 From: Miles Alan Date: Tue, 30 Jun 2020 22:29:32 -0500 Subject: [PATCH] Create empty file for contactsfile if missing --- scripts/core/sxmo_contacts.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/core/sxmo_contacts.sh b/scripts/core/sxmo_contacts.sh index 9c72212..9785063 100755 --- a/scripts/core/sxmo_contacts.sh +++ b/scripts/core/sxmo_contacts.sh @@ -10,6 +10,7 @@ CONTACTSFILE="$XDG_CONFIG_HOME"/sxmo/contacts.tsv LOGFILE="$XDG_CONFIG_HOME"/sxmo/modem/modemlog.tsv contacts() { + grep -q . "$CONTACTSFILE" || echo " " > "$CONTACTSFILE" RECENTCONTACTEDNUMBERSREVCHRON="$( cut -f3 "$LOGFILE" | tac |