I wanted to pass parameters in a shell script which calls a java program...
For example the current time is 2011:02:23 01:05 then I need to floor to nearest whole time like 1:00 (starttime parameter to java program) if its 1:05 and 1:15 (end time parameter to java program) the below timestamps I wanted to dynamically pass to a java program based on current time.
Example param(15min interval) to pass to java program via shell script.
java 2011:02:23 01:00 (start time) 2011.02.23 01:15 (end time)
java 2011.02.23 01:15 (starttime) 2011.02.23 01:30 (end time)
Can I ? or is there any way to generate the date with time in above specified format in unix ?
Note : This date: get current 15 minute interval doesnt serve my purpose.