On SSHkit-Github it's says:
All backends support the execute(*args), test(*args) & capture(*args)
From SSHkit-Rubydoc, I understand that execute is actually an alias to test?
What is the difference between test, execute, capture in Capistrano/SSHKit and when should I use either?
execute just executes command. raises error with non-
0exit.test method behaves exactly the same as
executehowever it returns boolean (trueif command exits with a0exit, andfalseotherwise). it'll usually be used for control flow in your tasks.capture method will execute the command on the first matching server, and will return the
stdoutoutput of the command as a string.stderroutput will be ignored (usels 2>&1to redirect stderr to stdout). raises error with non-0exit.