Fix bug in build-dir with single build dir

This commit is contained in:
Kenneth Benzie 2024-05-01 21:28:26 +01:00
parent 47082002f9
commit 1bdaa8ac08

View File

@ -84,6 +84,8 @@ EOF
integer index=0 integer index=0
if [[ ${#local_build_dirs} -eq 0 ]]; then if [[ ${#local_build_dirs} -eq 0 ]]; then
error "no build directories found"; return 1 error "no build directories found"; return 1
elif [[ ${#local_build_dirs} -eq 1 ]]; then
local_build_dir=${local_build_dirs[1]}
elif [[ ${#local_build_dirs} -gt 1 ]]; then elif [[ ${#local_build_dirs} -gt 1 ]]; then
if command -v fzf &> /dev/null; then if command -v fzf &> /dev/null; then
# Use fzf to select a build directory # Use fzf to select a build directory