From 1451bf6941f83de155e28d4d3954767d651cfde3 Mon Sep 17 00:00:00 2001 From: Jeremy Baxter Date: Tue, 19 Apr 2022 17:40:20 +1200 Subject: [PATCH] Removed the WIP update mechanism, it never worked out --- matrix-send | 14 +++++++------- versiondata | 1 - 2 files changed, 7 insertions(+), 8 deletions(-) delete mode 100644 versiondata diff --git a/matrix-send b/matrix-send index 0ac9158..803e92f 100755 --- a/matrix-send +++ b/matrix-send @@ -1,6 +1,8 @@ #!/bin/sh # matrix-send: a super-simple command-line matrix client +Version="dev_rolling" + [ -e /usr/bin/curl ] || printf "\033[31;1merror:\033[0m curl not found\n" ########################### @@ -12,9 +14,7 @@ error () { exit 1 } -conf_error () { - printf "\033[31;1mconfiguration error:\033[0m $1\n" - exit 2 +conf_error () { printf "\033[31;1mconfiguration error:\033[0m $1\n" exit 2 } vargrep () { @@ -62,9 +62,9 @@ NoCache () { nocache="true" } -################################### -#### Matrix-specific Functions #### -################################### +############################ +#### Specific Functions #### +############################ GetAccessToken () { [ -z "$manualAuth" ] && printf "Getting access token...\n" @@ -118,9 +118,9 @@ fi ############## [ -z "$1" ] && error "Message not specified" +[ "$1" = "-c" ] && ClearCache # Get token and cache it (unless NoCache is set) -[ "$1" = "-c" ] && ClearCache [ -e "$cacheloc/matrix-send/access-token" ] && token=$(cat $cacheloc/matrix-send/access-token) [ -e "$cacheloc/matrix-send/access-token" ] || GetAccessToken CacheAccessToken diff --git a/versiondata b/versiondata deleted file mode 100644 index 6bad906..0000000 --- a/versiondata +++ /dev/null @@ -1 +0,0 @@ -LatestVersion="dev_rolling"