From b483c72df77b59278013b372354af65e1aa0592b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Kucharczyk?= Date: Fri, 18 Nov 2022 14:05:06 +0100 Subject: [PATCH] Handle ~ in --db argument --- tag.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tag.sh b/tag.sh index 83edd66..dd65296 100755 --- a/tag.sh +++ b/tag.sh @@ -21,7 +21,7 @@ SCRIPT_NAME=$(basename "$0") DB_FILE="${PWD}/tags.db" -[ "${1:-}" = "--db" ] && DB_FILE="$2" && shift 2 +[ "${1:-}" = "--db" ] && DB_FILE=$(realpath "${2/#~/$HOME}") && shift 2 DB_SCHEMA="${SCRIPT_DIR}/database.sql"