curl_commands.rb

Path: lib/davclient/curl_commands.rb
Last Update: Tue Dec 06 21:46:33 +0000 2011

Templates for curl commands

Methods

Constants

CURL_PROPFIND = remove_newlines(curl_propfind_cmd)
CURL_PROPPATCH = remove_newlines(curl_proppatch_cmd)
CURL_DELETE = remove_newlines(curl_delete_cmd)
CURL_MKCOL = remove_newlines(curl_mkcol_cmd)
CURL_OPTIONS = "-i -X OPTIONS "
CURL_COPY = remove_newlines(curl_copy)
CURL_MOVE = remove_newlines(curl_move)
CURL_UPLOAD = "--upload-file"

Public Instance methods

Used to improve readability of curl commands that always needs to be on one line

[Source]

    # File lib/davclient/curl_commands.rb, line 9
 9: def remove_newlines(string)
10:   string.gsub("\n","").gsub(/ +/," ") + " "
11: end

[Validate]