mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-02-25 18:55:27 -06:00
made <source>...</source> and it's sub-elements conditional
This commit is contained in:
@@ -111,11 +111,16 @@
|
||||
|
||||
<% @channels.each do |channel| %>
|
||||
<channel type='<%= channel[:type] %>' >
|
||||
<source mode='<%= channel[:source_mode] %>'
|
||||
<%if channel[:source_mode] or channel[:source_path] %>
|
||||
<source
|
||||
<% if channel[:source_mode] %>
|
||||
mode='<%= channel[:source_mode] %>'
|
||||
<% end %>
|
||||
<% if channel[:source_path] %>
|
||||
path="<%= channel[:source_path] %>"
|
||||
<% end %>
|
||||
/>
|
||||
<% end %>
|
||||
<target type='<%= channel[:target_type] %>'
|
||||
<% if channel[:target_name] %>
|
||||
name="<%= channel[:target_name] %>"
|
||||
|
||||
Reference in New Issue
Block a user