Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Regex To Remove File Extension

by kennethk (Abbot)
on Dec 10, 2008 at 19:03 UTC ( #729480=note: print w/ replies, xml ) Need Help??


in reply to Regex To Remove File Extension

You could try s/(.*)\..*/$1/, which will greedily match up to the last '.' and then keep that part. For common regexes, you should probably also check out Regexp::Common.


Comment on Re: Regex To Remove File Extension
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://729480]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (6)
As of 2015-08-30 02:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The oldest computer book still on my shelves (or on my digital media) is ...













    Results (346 votes), past polls