Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: split efficiency needed

by markov (Scribe)
on Jan 21, 2004 at 14:21 UTC ( #322889=note: print w/ replies, xml ) Need Help??


in reply to split efficiency needed

I do not know you exact environment, but apparently you are processing ls output on a Unix/Linux system. If so, would it be possible to avoid using ls in the first place... The reason for this, is that the date format in the ls output depends on the locale settings and may therefore change. In my settings, it is 2004-01-21!

Maybe you can rewrite the code to this:

my $mtime = (stat $file)[9]; use POSIX 'strftime'; print strftime "any format you like", localtime $mtime;

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (5)
As of 2016-06-29 00:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My preferred method of making French fries (chips) is in a ...











    Results (365 votes). Check out past polls.