From 164bc1946c19fe04a8fe24504ec5f04941abd515 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Mat=C3=ADas=20Fonzo?= Date: Thu, 28 Feb 2019 18:12:11 -0300 Subject: [PATCH] qi: enhance incoming file detection to be upgraded --- qi/src/qi.in | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/qi/src/qi.in b/qi/src/qi.in index f74732f8..509e4a3b 100644 --- a/qi/src/qi.in +++ b/qi/src/qi.in @@ -887,12 +887,13 @@ resolve_mode() { upgrade_mode() { - # Complain if the package is not a regular file + # Complain if the package does not end in .tlz - test -f "$1" || { - warn "\`${1}' is not a regular file." + if ! fnmatch '*.tlz' "$1" + then + warn "\`${1}' does not end in .tlz" return 4 - } + fi # Get the filename incoming=$(basename -- "$1" .tlz) -- 2.11.4.GIT