Sha256: bc96f1591eb040e79234d56e6511538f597d77ff578d1550da392615d815bb89
Contents?: true
Size: 845 Bytes
Versions: 12
Compression:
Stored size: 845 Bytes
Contents
# frozen_string_literal: true module Uricp::Strategy class RemotePut include Uricp::Strategy::Common def appropriate? if compression_required? || conversion_required? debug "#{self.class.name}: not ready to upload" return false end case to.scheme when 'http', 'https' case from.scheme when 'file', 'pipe' return proposal if http_authentication? unsupported_transfer end end debug "#{self.class.name}: not appropriate" false end def command curl_upload_from(curl_source) end def proposal @proposed_options = options.dup @proposed_options['from_uri'] = to self end def curl_source if from.scheme == 'pipe' '-' else from.path end end end end
Version data entries
12 entries across 12 versions & 1 rubygems