Fix variable and function names
Move command selection code to libexec/option