07-19-2007
i had written a code to convert time of this format(01:40:38) to minutes as follows but looking for help how to complete as stated above (i.e the thread which i posted.... )
var=`echo "01:40:38 "`
echo "$var" | cut -d: -f1 > a1 ;
echo "$var" | cut -d: -f2 > a2 ;
echo "$var" | cut -d: -f3 > a3 ;
HH=`cat a1`;
Hours=$(($HH*3600));
MI=`cat a2`;
Minutes=$(($MI*60));
SS=`cat a3`
totseconds=$(($Hours+$Minutes+$SS))
echo $totseconds
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Where can i find info about the Time Service of UNIX ???
I need to "speak" with a machine which has UNIX os ( i know its IP address ) and to get from this machine its date or time.
I work with Cygwin on my machine.
any help will be welcomed .... (1 Reply)
Discussion started by: Inbal
1 Replies
2. UNIX for Advanced & Expert Users
Hi All,
What i am looking for:
i want to generate a dynamic system time for each and every data(line) which goes on generating data continously....
now i am using this script to append a time for dynamic data generation log file,
tail -f filename_error.log|awk -v var="$( date... (2 Replies)
Discussion started by: gsprasanna
2 Replies
3. Shell Programming and Scripting
Hi,
I have a tab delimited file with GMT time. How to convert the GMT to PST time and store the line only if date falls to 2 days ago date.
Say today is 16, date should be of 14. or else remove the line
abc - -
efg - -
hij - -
kln - - ... (10 Replies)
Discussion started by: sandy1028
10 Replies
4. Shell Programming and Scripting
Hello All,
I have a problem calculating the time difference between start and end timings...!
the timings are given by 24hr format..
Start Date : 08/05/10 12:55
End Date : 08/09/10 06:50
above values are in mm/dd/yy hh:mm format.
Now the thing is, 7th(08/07/10) and... (16 Replies)
Discussion started by: smarty86
16 Replies
5. Shell Programming and Scripting
Is this way of finding the time difference a correct way of doing it or is it error-prone.
#****Check if lastrun exist. If exists check if the difference is 1 hour or not and act accordingly***********************
if ; then
lastrun_time=`cat $LOG_DIR/lastrun`
curr_time=`date +%s`
... (4 Replies)
Discussion started by: sreekanthragi
4 Replies
6. Shell Programming and Scripting
Hi Friends,
I have 2 varaibles which contain
START=`date '+ %m/%d/%y %H:%M:%S'`
END=`date '+ %m/%d/%y %H:%M:%S'`
i want the time difference between the two variables in Seconds.
Plz help. (2 Replies)
Discussion started by: i150371485
2 Replies
7. Shell Programming and Scripting
I have a LOG file which looks like this
Import started at: Mon Jul 23 02:13:01 EDT 2012
Initialization completed in 2.146 seconds.
--------------------------------------------------------------------------------
--
Import summary for Import item: PolicyInformation... (8 Replies)
Discussion started by: biztank
8 Replies
8. Shell Programming and Scripting
Hi All :o,
I have some log files which contains these informations:
2013-04-24 09:11:34.018 INFO XXXXXXXXXXXX
2013-04-24 09:11:34.029 INFO YYYYYYYYYYYY
2013-04-24 09:11:34.039 INFO ZZZZZZZZZZZZZZZ
2013-04-24 09:12:21.295 INFO TTTTTTTTTTTTTTT
2013-04-24 09:12:21.489 INFO... (3 Replies)
Discussion started by: shariquehabib
3 Replies
9. Shell Programming and Scripting
I have a shell script that looks something like the following:
mysql -uroot db1 < db1.sql
mysql -uroot db2 < db2.sql
mysql -uroot db3 < db3.sql
mysql -uroot db4 < db4.sql
....
different db names in more than 160 lines.
I want to run this script with nohup and have a status later.
So,... (6 Replies)
Discussion started by: MKH
6 Replies
10. Shell Programming and Scripting
Hi
I have a system running uname -a
Linux cmovel-db01 2.6.32-38-server #83-Ubuntu SMP Wed Jan 4 11:26:59 UTC 2012 x86_64 GNU/Linux
I would like to capture the contents of /var/log/syslog from 11:00AM to 11:30AM and sent to this info via email.
I was thinking in set a cron entry at that... (2 Replies)
Discussion started by: fretagi
2 Replies
LEARN ABOUT OPENSOLARIS
totem-video-thumbnailer
totem-video-thumbnailer(1) User Commands totem-video-thumbnailer(1)
NAME
totem-video-thumbnailer - an interactive accessibility explorer.
SYNOPSIS
totem-video-thumbnailer [--jpeg] [--no-limit] [--size=size] [--time=seconds] [--verbose] input output URI [gst-std-options] [gnome-std-
options]
DESCRIPTION
totem-video-thumbnailer is used internally by GNOME applications such as nautilus(1) to generate PNG thumbnails of video files.
OPTIONS
The following options are supported:
-j, --jpeg Output the thumbnail as a JPEG instead of PNG.
-l, --no-limit Do not limit the thumbnailing time to 30 seconds.
-s, --size=size size of the thumbnail in pixels
-t, --time=seconds Do not limit the thumbnailing time to 30 seconds.
-v, --verbose Output debug information.
gnome-std-options Standard options available for use with most GNOME applications. See gnome-std-options(5).
OPERANDS
The following operands are supported:
input The input filename. This can be in any format that totem can play.
output The output filename, in PNG format by default, or in JPEG format if the --jpeg is used.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWgnome-media-player |
+-----------------------------+-----------------------------+
|Interface stability |Volatile |
+-----------------------------+-----------------------------+
SEE ALSO
nautilus(1), totem(1), attributes(5), gnome-std-options(5)
Comprehensive totem-video-thumbnailer documentation could be found under the Help menu in totem-video-thumbnailer.
NOTES
Written by Zack Cerza coe.neu.edu> for the Debian Project. Updated by Brian Cameron, Sun Microsystems Inc., 2007.
SunOS 5.11 08 Nov 2007 totem-video-thumbnailer(1)