From: Martin DeMello Date: 2009-06-01T15:29:23+09:00 Subject: [ruby-core:23654] Re: Counterpart to File.extname On Mon, Jun 1, 2009 at 6:11 AM, Michael Fellinger wrote: > require 'pathname' > > fn = Pathname('/a/b/c/d.e') > # # > > fn.dirname + fn.basename('.*') > # # Passing a suffix to basename is pretty unintuitive - I'd never have thought to look there. File.split (and/or Pathname#split) seems a lot cleaner to me. martin