def add_remotes
if (@new_resource.additional_remotes.length > 0)
@new_resource.additional_remotes.each_pair do |remote_name, remote_url|
converge_by("add remote #{remote_name} from #{remote_url}") do
Chef::Log.info "#{@new_resource} adding git remote #{remote_name} = #{remote_url}"
command = "git remote add #{remote_name} #{remote_url}"
if shell_out(command, run_options(:cwd => @new_resource.destination, :log_level => :info)).exitstatus != 0
@new_resource.updated_by_last_action(true)
end
end
end
end
end