Module: PathUtils
- Defined in:
- lib/hash_delegator.rb
Class Method Summary collapse
-
.resolve_path_or_substitute(path, expression) ⇒ String
Determines if a given path is absolute or substitutes a placeholder in an expression with the path.
Class Method Details
.resolve_path_or_substitute(path, expression) ⇒ String
Determines if a given path is absolute or substitutes a
placeholder in an expression with the path.
527 528 529 530 531 532 533 |
# File 'lib/hash_delegator.rb', line 527 def self.resolve_path_or_substitute(path, expression) if path.start_with?('/') path else expression.gsub('*', path) end end |