mirror of
https://github.com/samsonjs/vibetunnel.git
synced 2026-04-07 11:35:53 +00:00
Prioritize same path first
This commit is contained in:
parent
d0e92ea932
commit
014bbb9e1e
1 changed files with 7 additions and 3 deletions
|
|
@ -2,7 +2,7 @@
|
|||
# vt - VibeTunnel CLI wrapper
|
||||
# Simple bash wrapper that passes through to vibetunnel with shell expansion
|
||||
|
||||
VERSION="1.0.4"
|
||||
VERSION="1.0.5"
|
||||
|
||||
# Handle version flag
|
||||
if [ "$1" = "--version" ] || [ "$1" = "-v" ]; then
|
||||
|
|
@ -11,8 +11,12 @@ if [ "$1" = "--version" ] || [ "$1" = "-v" ]; then
|
|||
fi
|
||||
|
||||
# Find vibetunnel binary (prefer Go implementation)
|
||||
# First check if vibetunnel is in PATH (most common after installation)
|
||||
if command -v vibetunnel >/dev/null 2>&1; then
|
||||
# First check in the same directory as this script (when installed together)
|
||||
SCRIPT_DIR="$(dirname "$0")"
|
||||
if [ -x "$SCRIPT_DIR/vibetunnel" ]; then
|
||||
VIBETUNNEL="$SCRIPT_DIR/vibetunnel"
|
||||
elif command -v vibetunnel >/dev/null 2>&1; then
|
||||
# Check if vibetunnel is in PATH
|
||||
VIBETUNNEL="vibetunnel"
|
||||
elif [ -x "/usr/local/bin/vibetunnel" ]; then
|
||||
VIBETUNNEL="/usr/local/bin/vibetunnel"
|
||||
|
|
|
|||
Loading…
Reference in a new issue