dev/provisioning/modules/drush/templates/alias.erb
changeset 353 bf1bc6b08c46
equal deleted inserted replaced
352:d8a8c57f36c4 353:bf1bc6b08c46
       
     1 $aliases['<%= @alias_name %>'] = array(
       
     2 <% if @parent -%>
       
     3   'parent'       => '<%= @parent %>',
       
     4 <% end -%>
       
     5 <% if @root -%>
       
     6   'root'         => '<%= @root %>',
       
     7 <% end -%>
       
     8 <% if @uri -%>
       
     9   'uri'          => '<%= @uri %>',
       
    10 <% end -%>
       
    11 <% if @remote_host -%>
       
    12   'remote-host'  => '<%= @remote_host %>',
       
    13 <% end -%>
       
    14 <% if @remote_user -%>
       
    15   'remote-user'  => '<%= @remote_user %>',
       
    16 <% end -%>
       
    17 <% if @ssh_options -%>
       
    18   'ssh-options'  => '<%= @ssh_options %>',
       
    19 <% end -%>
       
    20 <% if @db_url -%>
       
    21   'db-url'       => '<%= @db_url %>',
       
    22 <% end -%>
       
    23 <% if @custom_options -%>
       
    24   <%- @custom_options.each do |key, value| -%>
       
    25   <%= "'#{key}' => '#{value}'" %>,
       
    26   <%- end -%>
       
    27 <% end -%>
       
    28 <% if @path_aliases -%>
       
    29   'path-aliases' => array(
       
    30   <%- @path_aliases.each do |key, value| -%>
       
    31     <%= "'#{key}' => '#{value}'" %>,
       
    32   <%- end -%>
       
    33   ),
       
    34 <% end -%>
       
    35 <% if @command_specific -%>
       
    36   'command-specific' => array(
       
    37   <%- @command_specific.each do |command, options| -%>
       
    38     <%= "'#{command}'" %> => array(
       
    39     <%- options.each do |key, value| -%>
       
    40       <%- value = "'#{value}'" unless [true, false].include? value -%>
       
    41       <%= "'#{key}' => #{value}" -%>,
       
    42     <%- end -%>
       
    43     ),
       
    44   <%- end -%>
       
    45   ),
       
    46 <% end -%>
       
    47 <% if @source_command_specific -%>
       
    48   'source-command-specific' => array(
       
    49   <%- @source_command_specific.each do |command, options| -%>
       
    50     <%= "'#{command}'" %> => array(
       
    51     <%- options.each do |key, value| -%>
       
    52       <%- value = "'#{value}'" unless [true, false].include? value -%>
       
    53       <%= "'#{key}' => #{value}" -%>,
       
    54     <%- end -%>
       
    55     ),
       
    56   <%- end -%>
       
    57   ),
       
    58 <% end -%>
       
    59 <% if @target_command_specific -%>
       
    60   'target-command-specific' => array(
       
    61   <%- @target_command_specific.each do |command, options| -%>
       
    62     <%= "'#{command}'" %> => array(
       
    63     <%- options.each do |key, value| -%>
       
    64       <%- value = "'#{value}'" unless [true, false].include? value -%>
       
    65       <%= "'#{key}' => #{value}" -%>,
       
    66     <%- end -%>
       
    67     ),
       
    68   <%- end -%>
       
    69   ),
       
    70 <% end -%>
       
    71 );
       
    72