From 1e7d726bf8773f0a27d8ebd94ef1ecef39ced5de Mon Sep 17 00:00:00 2001 From: 12425 Date: Sat, 3 Apr 2021 15:54:01 -0700 Subject: [PATCH] Fix for Windows. Windows sqlite3.exe generates file in dos format and the extra `\r` causes wrong curl command and deletion failure. Instead of `cat` lines, use `sed` to trim the `\r`. --- jnrmor | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jnrmor b/jnrmor index fd47e2a..6f1f688 100755 --- a/jnrmor +++ b/jnrmor @@ -280,7 +280,7 @@ if [ "$fflag" != "1" ]; then fi fi -for id in `cat $TMPFILE` +for id in `sed 's/\s\+$//' $TMPFILE` do curlCMD="curl -s -X DELETE http://localhost:${CLIPPER_PORT}/resources/${id}?token=${CLIPPER_TOKEN}" debug "$curlCMD"