lib/ash/common.rb in capistrano-ash-1.1.4 vs lib/ash/common.rb in capistrano-ash-1.1.5

- old
+ new

@@ -12,6 +12,12 @@ # Prompts user entry # Params: # +prompt+ def text_prompt(prompt="Value: ") Capistrano::CLI.ui.ask(prompt) { |q| q.echo = true } +end + +# Test to see if a file exists by providing +# the full path to the expected file location +def remote_file_exists?(full_path) + 'true' == capture("if [ -e #{full_path} ]; then echo 'true'; fi").strip end \ No newline at end of file