diff options
author | Duncan Overbruck <mail@duncano.de> | 2020-09-13 17:44:47 +0200 |
---|---|---|
committer | Leah Neukirchen <leah@vuxu.org> | 2020-09-13 18:24:41 +0200 |
commit | 2e884539fb246221905f6945361c032feb4ad604 (patch) | |
tree | c294be0239b3da2f726cc119e2b16873481b6cb4 | |
parent | 79fdecac4c9165098c376655ccf703abd2cc8db8 (diff) | |
download | xtools-2e884539fb246221905f6945361c032feb4ad604.tar.gz xtools-2e884539fb246221905f6945361c032feb4ad604.tar.xz xtools-2e884539fb246221905f6945361c032feb4ad604.zip |
xlocate: error out if the database doesn't exist
Closes: #199 [via git-merge-pr]
-rwxr-xr-x | xlocate | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/xlocate b/xlocate index 49b6ac5..2eec04a 100755 --- a/xlocate +++ b/xlocate @@ -81,7 +81,6 @@ if [ -d "$XLOCATE_GIT" ]; then git -c grep.lineNumber=false --git-dir="$XLOCATE_GIT" grep -- "$@" @ | sed 's/^@://; s/:/\t/' | grep . else - echo "xlocate: database not found, using xbps-query." 1>&2 - xbps-query --regex -Ro '.*'"$@" | - sed 's/ *([^)]*)$//; s/^\([^ ]*\)-[^-]*: /\1\t/' + echo "xlocate: database not found, please use xlocate -S." 1>&2 + exit 1 fi |