Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
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.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://729480]
help
Chatterbox?
[Corion]: Last year we renamed everybody with a name collision to "Alice". This year, we're renaming the remaining collisions to 'Bob' ;-)
[stevieb]: sigh... should have looked to see if version 2.36.1 was higher or lower than 2.36 when uploading to CPAN :/
[Corion]: :-D

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (12)
As of 2017-01-19 14:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you watch meteor showers?




    Results (170 votes). Check out past polls.