Module: EasyAppHelper::Scripts::ParametersHelper
- Defined in:
- lib/easy_app_helper/scripts/parameters_helper.rb
Instance Method Summary collapse
-
#normalize_param(param) ⇒ String or Symbol
Allows to specify a Ruby Symbol as a string.
Instance Method Details
#normalize_param(param) ⇒ String or Symbol
Allows to specify a Ruby Symbol as a string. Supposed to be used to pass symbols from the command line.
12 13 14 15 16 17 |
# File 'lib/easy_app_helper/scripts/parameters_helper.rb', line 12 def normalize_param(param) param.match(/^:(?<param>.+)$/) do |md| param = md['param'].to_sym end param end |