UK Holidays: Difference between revisions
Jump to navigation
Jump to search
remind>Admin (New page: :''Main article: Remind'' These are some standard UK holidays in remind format, add them as an include in your .reminders file. Some notes: * These are the England & Wales bank holid...) |
remind>Fastfret79 (Added working Christmas & Boxing Day Bank Holiday Calcs) |
||
Line 76: | Line 76: | ||
UK Christmas Day & Boxing Day Bank Holiday | UK Christmas Day & Boxing Day Bank Holiday | ||
<pre> | <pre> | ||
# | # First calculate the first weekday on or after 25th Dec | ||
# Force it to current year otherwise it will search forward into next year | |||
SET XmasBH evaltrig("Mon Tue Wed Thu Fri 25 Dec", date(year(today()), 12, 25)) | |||
# | #Set this date as Christmas Bank Holiday | ||
REM | REM [XmasBH] MSG Christmas Bank Holiday | ||
# | #Set the next day (skipping Sat and Sun) to Boxing Day Bank Holiday | ||
REM [trigger(XmasBH+1)] OMIT Sat Sun AFTER MSG Boxing Day Bank Holiday | |||
REM | |||
</pre> | </pre> | ||
[[Category:Remind]] | [[Category:Remind]] |
Revision as of 19:17, 3 April 2011
- Main article: Remind
These are some standard UK holidays in remind format, add them as an include in your .reminders file.
Some notes:
- These are the England & Wales bank holidays, feel free to add the Scotland and Ireland ones.
- The Bank Holiday date definitions are taken from the Bank Holidays wikipedia page.
- The May, Spring and Summer bank holidays, and the Boxing day bank holiday aren't OMITs because they use weekday date specifiers, which generate an error ("Unknown token: `Mon' (OMIT)"). If anyone knows a way around this, please correct them.
- If anyone can think of a way to add a reminder for Remembrance Sunday—defined as the Sunday nearest (before or after) the 11th of November—please add it.
- Can anyone think of rules to accommodate Christmas Day or New Years Day falling on a Sat or Sun? Eg. 27th/28th December 2010. This is especially complex when Christmas Day is a Sat as Boxing Day becomes the following Mon and the Tue an additional Holiday.
OMIT 01 Jan MSG New Year's Day (Bank Holiday)% REM Mon 1 May MSG May Day (Bank Holiday)% REM Mon 1 Jun -7 MSG Spring Bank Holiday (Whitsun)% REM Mon 1 Sep -7 MSG Summer Bank Holiday% OMIT 25 Dec MSG Christmas Day% # Boxing Day is the first weekday after Christmas REM Mon Tue Wed Thu Fri 26 Dec MSG Boxing Day (Bank Holiday)% # Easter stuff SET easter EASTERDATE(YEAR(TODAY())) OMIT [TRIGGER(easter-2)] MSG Good Friday (Bank Holiday)% REM [TRIGGER(easter)] MSG Easter Sunday% OMIT [TRIGGER(easter+1)] MSG Easter Monday (Bank Holiday)% # Mother's Day is defined as the 4th Sunday of Lent. Lent begins on # Ash Wednesday (easter-46), so the 4th Sunday is easter-21 REM [TRIGGER(easter-21)] MSG Mother's Day% # other annual dates or holidays I want to be reminded of: REM 25 Jan MSG Burns Night% REM 14 Feb MSG Valentine's Day% REM 01 Mar MSG St. David's Day% REM 17 Mar MSG St. Patrick's Day% REM 21 Apr MSG The Queen's Birthday (her actual birthday)% REM 23 Apr MSG St. George's Day% REM 08 May MSG VE Day% REM Sun 15 Jun MSG Father's Day% REM 31 Oct MSG Halloween% REM 05 Nov MSG Bonfire Night% REM 11 Nov MSG Rememberance Day% REM 30 Nov MSG St. Andrew's Day% # Western European Summer Time definitions. I'm not sure what the # algorithm is for deciding these, so these are the mandated dates # through to 2011. See the wikipedia page for details: # http://en.wikipedia.org/wiki/Western_European_Summer_Time REM 25 Mar 2007 British Summer Time begins (clocks go forward 1 hour)% REM 28 Oct 2007 British Summer Time ends (clocks go back 1 hour)% REM 30 Mar 2008 British Summer Time begins (clocks go forward 1 hour)% REM 26 Oct 2008 British Summer Time ends (clocks go back 1 hour)% REM 29 Mar 2009 British Summer Time begins (clocks go forward 1 hour)% REM 25 Oct 2009 British Summer Time ends (clocks go back 1 hour)% REM 28 Mar 2010 British Summer Time begins (clocks go forward 1 hour)% REM 31 Oct 2010 British Summer Time ends (clocks go back 1 hour)% REM 27 Mar 2011 British Summer Time begins (clocks go forward 1 hour)% REM 30 Oct 2011 British Summer Time ends (clocks go back 1 hour)%
- The official government UK Bank Holidays can be found at the UK Gov DTI site includes Scotland and Northern Ireland.
- UK Summertime (BST) is defined as starting at 0100 on the last Sunday March and ending at 0100 on the last Sunday of October.
Using these definitions for Summer Time
# British Summer Time # Untested but should work REM Last Sunday of March AT 0100 MSG BST Begins (Clocks go Fowards 1hr)% REM Last Sunday of October AT 0100 MSG BST Ends (Clocks go Backwards 1hr)%
UK Christmas Day & Boxing Day Bank Holiday
# First calculate the first weekday on or after 25th Dec # Force it to current year otherwise it will search forward into next year SET XmasBH evaltrig("Mon Tue Wed Thu Fri 25 Dec", date(year(today()), 12, 25)) #Set this date as Christmas Bank Holiday REM [XmasBH] MSG Christmas Bank Holiday #Set the next day (skipping Sat and Sun) to Boxing Day Bank Holiday REM [trigger(XmasBH+1)] OMIT Sat Sun AFTER MSG Boxing Day Bank Holiday