Sha256: d074afe4a6b339a8cf5be15744c01ae218741582b8759bee019390d32d62dfa2
Contents?: true
Size: 315 Bytes
Versions: 53
Compression:
Stored size: 315 Bytes
Contents
require 'cgi' module Seahorse # @api private module Util class << self def uri_escape(string) CGI.escape(string.encode('UTF-8')).gsub('+', '%20').gsub('%7E', '~') end def uri_path_escape(path) path.gsub(/[^\/]+/) { |part| uri_escape(part) } end end end end
Version data entries
53 entries across 53 versions & 1 rubygems