bradp / vv

:globe_with_meridians: Variable VVV - a VVV Site Creation Wizard.‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ ‎ :x: This project is no longer maintained. Please update your copy of VVV , which has most of the vv features built in.
GNU General Public License v2.0
1k stars 90 forks source link

Fix for #144 – vagrant ssh not working #334

Closed ollietreend closed 7 years ago

ollietreend commented 7 years ago

@bradp This should be a suitable fix for the issue discussed in #144.

I've replaced the use of echo with exec. So rather than 'proxying' the vagrant command to a non-interactive sub-shell and just returning the output, exec will replace the current interactive shell with the vagrant command.

Not only does this mean vv vagrant ssh will work as expected, but it also means that other niceties are retained, such as text colour and formatting.

Note also the use of ${@:2} instead of $2, causing all parameters after 'vagrant' to be retained. This means more complicated commands can be proxied to vagrant, e.g. vv vagrant ssh --help will execute vagrant ssh --help.

bradp commented 7 years ago

Thanks. I'll test + tag a new version shortly.