Rewrite `bundle exec` wrapper to be more robust