My problem is with the find command. After looking through the forum I've got -
find . -mtime 2 -name "*"
which gives me a list of all the files modified in the last 2 days.
How do I change this to list files modified in the last 2 hours?
Sorry if this question is already on the forum... (4 Replies)
Last week I was using the command:
' find /directory -mtime -2 -print' and it showed all the files modified within that period. However, now it only displays the directories and not the files modified. The only thing that changed is that I was granted access to some files.
Thanks (2 Replies)
Hi ,
I am trying to find out the List of files modified or added aftter installation of any component on SUN solaris box .
But i am not able to do it using ls or find command .
Can somebody help me out ?
Thanks
Sanjay Gupta (2 Replies)
Hi All,
I have a requirement to find out the files which are modified in the last 10 minutes.
I tried the find command with -amin and -mmin options, but its not working on my AIX server.
Can anyone of you could help me.
Thanks in advance for your help.
Raju (3 Replies)
Hello :D
I am on the shell prompt in a directory, with couple of zip files in it.
How can I
unzip '*.zip' where modified time > 05:00
...please help
Regards
SunnyK (3 Replies)
Hi,
I have some log files created in the following fashion
Ex:
file name modified date
1) s.log1 01-jan-08
2) s.log2 02-jan-08
3) s.log3 03-jan-08
4) s.log4 04-jan-08
Now I want to have the latest 2 logs and delete the others.
Can you tell me the one liner /... (1 Reply)
Hi,
I am new bie to Unix. Might be a simple question I am asking.
I want to find the last modified time of a file and find the difference between the currrent time and the last modified time. Appreciate, if someone can throw some light on what commands can be used.
Cheers,
James (2 Replies)
Actually i did modification in a file on server by mistake, now its showing current time stamp, is there any way to set the files modified date and stamp to last modifies time.
Please advice here.Thanks in advance.:b: (7 Replies)
I have a huge list of files in an Unix directory (around 10000 files).
I need to be able to search for a certain keyword only within files that are modified between certain date and time, say for e.g 2012-08-20 12:30 to 2012-08-20 12:40
Can someone let me know what would be the fastest way... (10 Replies)
Version Info
+++++++++++++++
RHEL 5.4
Since ls command lists file sizes in Bytes which can be long I use du command like below.
I have run the du command for the below files as shown below.
But I want pipe this output to ls command just to see the modified timestamp for these files. ... (7 Replies)
Discussion started by: kraljic
7 Replies
LEARN ABOUT DEBIAN
time::duration::parse
Time::Duration::Parse(3pm) User Contributed Perl Documentation Time::Duration::Parse(3pm)NAME
Time::Duration::Parse - Parse string that represents time duration
SYNOPSIS
use Time::Duration::Parse;
my $seconds = parse_duration("2 minutes and 3 seconds"); # 123
DESCRIPTION
Time::Duration::Parse is a module to parse human readable duration strings like 2 minutes and 3 seconds to seconds.
It does the opposite of duration_exact function in Time::Duration and is roundtrip safe. So, the following is always true.
use Time::Duration::Parse;
use Time::Duration;
my $seconds = int rand 100000;
is( parse_duration(duration_exact($seconds)), $seconds );
FUNCTIONS
parse_duration
$seconds = parse_duration($string);
Parses duration string and returns seconds. When it encounters an error in a given string, it dies an exception saying "Unknown
timespec: blah blah blah". This function is exported by default.
AUTHOR
Tatsuhiko Miyagawa <miyagawa@bulknews.net>
COPYRIGHT
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Some internal code is taken from Cache and Cache::Cache modules on CPAN.
SEE ALSO
Date::Manip, DateTime::Format::Duration, <http://use.perl.org/~miyagawa/journal/30310>
perl v5.10.0 2008-06-02 Time::Duration::Parse(3pm)