Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Answer: How do I extract a file name from a path string

by t0mas (Priest)
on Oct 04, 2000 at 13:21 UTC ( #35238=categorized answer: print w/replies, xml ) Need Help??

Q&A > strings > How do I extract a file name from a path string - Answer contributed by t0mas

The File::Basename module is probably what you want.
use File::Basename; ( $name, $path, $suffix ) = fileparse( $filename_with_path, "\.[^.]*" +);
/brother t0mas

Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
[ambrus]: Corion: schmorp points out https://metacpan. org/pod/release/ KARASIK/Prima-1. 49/pod/Prima/File. pod,
[ambrus]: so there's an IO waiter (Prima::File) and a timer (Prima::Timer) maybe it's possible to write an AnyEvent loop driver over it, a saner one than POE

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (15)
As of 2016-12-07 16:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (130 votes). Check out past polls.