Module: HCL
- Defined in:
- lib/hcl.rb,
lib/hcl/version.rb,
lib/hcl/monkey_patch.rb
Defined Under Namespace
Classes: ASTVisitor, Decoder, Generator, Parser, Parslet
Constant Summary collapse
- VERSION =
"0.1.0"
Class Method Summary collapse
Class Method Details
.escape_key(key) ⇒ Object
2 3 4 5 6 7 8 9 |
# File 'lib/hcl/monkey_patch.rb', line 2 def self.escape_key(key) str = key.to_s pos = str =~ /[^a-zA-Z0-9_\-]/ return str if pos.nil? str.dump end |