wrapped ruby's File.basename() into basename custom function