Sponsored Content
Top Forums Shell Programming and Scripting Calculating start and end of UK summertime Post 302517747 by DGPickett on Wednesday 27th of April 2011 03:30:02 PM
Old 04-27-2011
Some zdump can trim themselves:
Code:
zdump -v -c '2011,2011' Europe/London

Still, it begs the question of the need for some utility where you can ask for the dom of a Sunday in Mar 2011 with 9 < dom < 17. I suppose if you took cal apart a bit, it might not be too hard to make a calendar selector utility, maybe just a cal option / enhancement. You might tell it to start at 3/10/2011 and find 1 Sunday.

Last edited by jim mcnamara; 04-28-2011 at 11:32 AM.. Reason: finish code tags
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

extract a particular start and end pattern from a line

hi In the foll example the whole text in a single line.... i want to extract text from IPTel to RTCPBase.h. want to use this acrooss the whole file Updated: IPTel\platform\core\include\RTCPBase.h \main\MWS2051_Sablime_Int\1... (7 Replies)
Discussion started by: manish205
7 Replies

2. UNIX for Advanced & Expert Users

Complete dump from start to the end

Hi all... I was accidentally wipe off my iphone and lost all the data in it:(. So I tried to use dd to create an image from iphone and ssh to the Mac by using: dd if=/dev/disk | ssh user@MacIP of='image.img' Then I mount this image on Mac/Windows and run recovery software because most of the... (1 Reply)
Discussion started by: seraphc
1 Replies

3. Shell Programming and Scripting

String as both start and end anchors in awk

Not sure if the title of this thread makes sense, but hopefully my explanation will. I'm using awk to print some stats from an apache accesslog. I would like to specify the regexp condition where only the two root pages of "index.html" and "/" are counted in my results. What I can't figure out... (3 Replies)
Discussion started by: picassolsus
3 Replies

4. Shell Programming and Scripting

searching between start and end time

Hello All, Below mentioned is my log file. I want to make a script which ask for start time and then end time and then search particular word between those lines. Like start time:2 end time: 4 and then search all values starting from cell 84 between this time. Please Help ... (2 Replies)
Discussion started by: wakhan
2 Replies

5. Shell Programming and Scripting

Perl regex using /START/../END/

I need help with perl code. I have a data file with lots of data example: data.txt file START DATA1 sjdfh kjhdf DATA2 sdkjfhk jds dshfgdf ... Around 20 - 30 lines END LDDDD awdkjasd a sdkahgdk jasdh SOME CRAP Some EMPTY lines etc START DATA1 sjdfh kjhdf DATA2 sdkjfhk jds... (2 Replies)
Discussion started by: chakrapani
2 Replies

6. Programming

Returning start/end indices

I have an array of distances and a len, for example len = 323 dist = I want to calculate the start and end index values around each distance in the array with a length of len from it. Values in dist are stored in ascending order. (4 Replies)
Discussion started by: kristinu
4 Replies

7. Shell Programming and Scripting

Remove lines between the start string and end string including start and end string Python

Hi, I am trying to remove lines once a string is found till another string is found including the start string and end string. I want to basically grab all the lines starting with color (closing bracket). PS: The line after the closing bracket for color could be anything (currently 'more').... (1 Reply)
Discussion started by: Dabheeruz
1 Replies

8. Shell Programming and Scripting

How can I search with start and end criteria?

Hello I'm using cygwin and wouldlike extract information from an xml file according specific values, but don't know how. Let's say in a file content looks like this: <tab> SURNAME=Mustermann NAME=Max CUSTOMER SINCE= 18.01.2000 ADDRESS=Birmingham ... (2 Replies)
Discussion started by: witchblade
2 Replies

9. Shell Programming and Scripting

Retrieving sequences corresponding to start and end position

Hi all, I have a fasta file of a reference sequnce, I will like to retrieve sequences corresponding to a list of start and end position in another file >my_ref_seq GCCCTATAAGGGCAGAAGCTTGTCCTTCTTGTGCCAGTTATGACGTTTGTCCTAACTGCACATCTGGTAG... (4 Replies)
Discussion started by: Ibk
4 Replies

10. UNIX for Beginners Questions & Answers

Splitting week start date and end date based on custom period start dates

Below are my custom period start and end dates based on a calender, these dates are placed in a file, for each period i need to split into three weeks for each period row, example is given below. Could you please help out to achieve solution through shell script.. File content: ... (2 Replies)
Discussion started by: nani2019
2 Replies
INTLCALENDAR.GETSKIPPEDWALLTIMEOPTION(3)				 1				  INTLCALENDAR.GETSKIPPEDWALLTIMEOPTION(3)

IntlCalendar::getSkippedWallTimeOption - Get behavior for handling skipped wall time

	Object oriented style

SYNOPSIS
public int IntlCalendar::getSkippedWallTimeOption (void ) DESCRIPTION
Procedural style int intlcal_get_skipped_wall_time_option (IntlCalendar $cal) Gets the current strategy for dealing with wall times that are skipped whenever the clock is forwarded during dailight saving time start transitions. The default value is IntlCalendar::WALLTIME_LAST. The calendar must be lenient for this option to have any effect, otherwise attempting to set a non-existing time will cause an error. This function requires ICU 4.9 or later. PARAMETERS
o $cal - The IntlCalendar resource. RETURN VALUES
One of the constants IntlCalendar::WALLTIME_FIRST, IntlCalendar::WALLTIME_LAST or IntlCalendar::WALLTIME_NEXT_VALID. EXAMPLES
Example #1 IntlCalendar.getSkippedWallTimeOption(3) <?php ini_set('date.timezone', 'Europe/Lisbon'); ini_set('intl.default_locale', 'en_US'); ini_set('intl.error_level', E_WARNING); //On March 31st at 0100, the clock goes forward 1 hour and from GMT+00 to GMT+01 $cal = new IntlGregorianCalendar(2013, 2 /* March */, 31, 1, 30); var_dump( $cal->isLenient(), // true $cal->getSkippedWalltimeOption() // 0 WALLTIME_LAST ); $formatter = IntlDateFormatter::create( NULL, IntlDateFormatter::FULL, IntlDateFormatter::FULL, 'UTC' ); var_dump($formatter->format($cal->getTime() / 1000)); $cal->setSkippedWallTimeOption(IntlCalendar::WALLTIME_FIRST); var_dump($cal->getSkippedWalltimeOption()); // 1 WALLTIME_FIRST $cal->set(IntlCalendar::FIELD_HOUR_OF_DAY, 1); var_dump($formatter->format($cal->getTime() / 1000)); $cal->setSkippedWallTimeOption(IntlCalendar::WALLTIME_NEXT_VALID); var_dump($cal->getSkippedWalltimeOption()); // 2 WALLTIME_NEXT_VALID $cal->set(IntlCalendar::FIELD_HOUR_OF_DAY, 1); var_dump($formatter->format($cal->getTime() / 1000)); The above example will output: bool(true) int(0) string(40) "Sunday, March 31, 2013 at 1:30:00 AM GMT" int(1) string(41) "Sunday, March 31, 2013 at 12:30:00 AM GMT" int(2) string(40) "Sunday, March 31, 2013 at 1:00:00 AM GMT" SEE ALSO
IntlCalendar::getRepeatedWallTimeOption, IntlCalendar::setSkippedWallTimeOption, IntlCalendar::setRepeatedWallTimeOption. PHP Documentation Group INTLCALENDAR.GETSKIPPEDWALLTIMEOPTION(3)
All times are GMT -4. The time now is 01:45 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy