From 0ebb9f0a9a0acd7e2ffda6bb597fc8e52799af4d Mon Sep 17 00:00:00 2001 From: Ferran Basora Date: Wed, 30 Mar 2022 15:36:31 +0000 Subject: [PATCH] Changing grep check for OpenBSD compatibility The different implementations of `grep` that exist in Linux and OpenBSD makes the tmux-thumbs script to crash. Changing the command to be compatible. --- tmux-thumbs.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tmux-thumbs.sh b/tmux-thumbs.sh index 1a650a6..7e060e8 100755 --- a/tmux-thumbs.sh +++ b/tmux-thumbs.sh @@ -7,7 +7,7 @@ RELEASE_DIR="${CURRENT_DIR}/target/release" THUMBS_BINARY="${RELEASE_DIR}/thumbs" TMUX_THUMBS_BINARY="${RELEASE_DIR}/tmux-thumbs" -VERSION=$(grep 'version =' "${CURRENT_DIR}/Cargo.toml" | grep -oe "[0-9]\+.[0-9]\+.[0-9]\+") +VERSION=$(grep 'version =' "${CURRENT_DIR}/Cargo.toml" | grep -o "\".*\"" | sed 's/"//g') if [ ! -f "$THUMBS_BINARY" ]; then tmux split-window "cd ${CURRENT_DIR} && bash ./tmux-thumbs-install.sh"