Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b4c03078 authored by Jim Tang's avatar Jim Tang Committed by android-build-merger
Browse files

Merge "Envsetup: Fix lunch choice with number in zsh" am: 2647067a am: 845a5889

am: c0d20c3e

Change-Id: I66ca3e2c54454d86e455e62643ddc8ce4876e3e7
parents e85994c1 c0d20c3e
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -585,8 +585,14 @@ function lunch()
        local choices=($(TARGET_BUILD_APPS= LUNCH_MENU_CHOICES="${LUNCH_MENU_CHOICES[@]}" get_build_var COMMON_LUNCH_CHOICES))
        if [ $answer -le ${#choices[@]} ]
        then
            # array in zsh starts from 1 instead of 0.
            if [ -n "$ZSH_VERSION" ]
            then
                selection=${choices[$(($answer))]}
            else
                selection=${choices[$(($answer-1))]}
            fi
        fi
    else
        selection=$answer
    fi