Method: Pathname#sub

Defined in:
lib/pathname.rb

#sub(pattern, *rest, &block) ⇒ Object

Return a pathname which is substituted by String#sub.



253
254
255
# File 'lib/pathname.rb', line 253

def sub(pattern, *rest, &block)
  self.class.new(@path.sub(pattern, *rest, &block))
end