Skip Menu |

This queue is for tickets about the PathTools CPAN distribution.

Report information
The Basics
Id: 11442
Status: new
Priority: 0/
Queue: PathTools

People
Owner: Nobody in particular
Requestors:
Cc:
AdminCc:

Bug Information
Severity: Wishlist
Broken in: (no value)
Fixed in: (no value)

Attachments


Subject: add dirname, basename, fileparse
Obsolete File::Basename, add dirname, basename, fileparse to File::Spec http://www.perlmonks.org/index.pl?node_id=383907 http://perlmonks.thepen.com/250534.html
Download file.spec.basename.txt
application/octet-stream 6.2k

Message body not shown because it is not plain text.

[guest - Wed Feb 9 10:06:50 2005]: Show quoted text
> Obsolete File::Basename, add dirname, basename, fileparse to > File::Spec > http://www.perlmonks.org/index.pl?node_id=383907 > http://perlmonks.thepen.com/250534.html
Is this a suggestion that File::Basename use File::Spec internally or that File::Spec add fileparse, basename and dirname methods? Keep in mind the recent round of File::Basename fixes to dirname and basename. The docs lied, they do not do what you think. They emulate the dirname(1) and basename(1) shell commands which do NOT always return the directory name and file name. The log of recent changes. http://public.activestate.com/cgi-bin/perlbrowse?file=lib%2FFile%2FBasename.pm&log=1 The current development version of the module. http://public.activestate.com/cgi-bin/perlbrowse?file=lib%2FFile%2FBasename.pm&blame=1 The current test suite. http://public.activestate.com/cgi-bin/perlbrowse?file=lib%2FFile%2FBasename.t&rev=
I can't claim to follow this discussion (maybe because it ranges over so many forums), but File::Spec already has a method to separate directories from files: splitpath(). The code on perlmonks seemed to be confused about what "suffix" means, as it seems to be treating it as the volume name. -Ken