From 8e6531764b00b29259fc59bd4e1f16e019bc3f2a Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Sat, 13 Jun 2026 18:33:34 +0200 Subject: fix: resolve relative nvchecker keyfile path against config dir MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit nvchecker resolves a relative oldver/newver/keyfile path against the config file's directory, not the CWD. _nvchecker_newver_path returned the raw relative string (e.g. "new_ver.json"), so nvchecker_latest's [[ -f ]] check ran against whatever CWD 'mkhint -C' was launched from — almost never the config dir. Result: every package reported 'no nvchecker result' and the run said 'all up to date' despite nvchecker having found updates. Resolve non-absolute keyfile paths against dirname(NVCHECKER_CONFIG). T35 covers a relative newver path with the keyfile beside the config. Co-Authored-By: Claude Opus 4.8 --- mkhint | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'mkhint') diff --git a/mkhint b/mkhint index 05094e9..7311ffe 100755 --- a/mkhint +++ b/mkhint @@ -155,6 +155,11 @@ _nvchecker_newver_path() { [[ -z "$path" ]] && return 1 # expand a leading ~ to $HOME path="${path/#\~/$HOME}" + # nvchecker resolves a relative keyfile path against the config file's + # directory (not the CWD), so do the same here. + if [[ "$path" != /* ]]; then + path="$(dirname "$NVCHECKER_CONFIG")/$path" + fi printf '%s\n' "$path" } -- cgit v1.2.3