Method: String#escape_for_cmd
- Defined in:
- lib/libis/tools/extend/string.rb
#escape_for_cmd ⇒ Object
Escape double quotes for usage in passing through scripts
43 44 45 |
# File 'lib/libis/tools/extend/string.rb', line 43 def escape_for_cmd self.gsub(/"/) { |s| '\\\\\\' + s[0].to_s } end |