lib/capistrano/tasks/z10_remote_db_diff.rb
# Executes the SQL diff files on the specified db_dest_names.
#
# If db_dest_names is an Array, each file will be executed on each item found in the
# array.
#
Executes the SQL diff files on the specified db_dest_names.
If db_dest_names is an Array, each file will be executed on each item found in the
array.
Executes the SQL diff files on the specified db_dest_names . If db_dest_names is an Array each file will be executed on each item found in the array .
def apply_locally_diff_files_on_db( filenames, db_host, db_user, db_pwd, db_dest_names, dest_verbose_name )
    if filenames.size > 0
      puts "\r\n\r\n\t** LOCAL Staging DB-DIFF APPLY: #{ dest_verbose_name } **"
      filenames.each do |filename|
        if db_dest_names.instance_of?( Array )      
          db_dest_names.each do |db_name|
            execute_file_or_exit( filename, db_host, db_user, db_pwd, db_name )
          end
        else
          execute_file_or_exit( filename, db_host, db_user, db_pwd, db_dest_names )
        end
      end
    end
  end
def apply_locally_diff_files_on_db ( filenames , db_host , db_user , db_pwd , db_dest_names , dest_verbose_name ) if filenames . size > 0 puts "\r\n\r\n\t** LOCAL Staging DB-DIFF APPLY: #{ dest_verbose_name } **" filenames . each do | filename | if db_dest_names . instance_of? ( Array ) db_dest_names . each do | db_name | execute_file_or_exit ( filename , db_host , db_user , db_pwd , db_name ) end else execute_file_or_exit ( filename , db_host , db_user , db_pwd , db_dest_names ) end end end end
Executes the SQL diff files on the specified db_dest_names.
Executes the SQL diff files on the specified db_dest_names .
# Multi DB apply: # Single DB apply:
filenames
<not_specific>
db_host
<not_specific>
db_user
<not_specific>
db_pwd
<not_specific>
db_dest_names
<not_specific>
dest_verbose_name
<not_specific>