<p>Great script Ken! I have been giving out <a href="http://sf-lug.com">sf-lug.com</a> for awhile to avoid broken pages. I hope this gets fixed for good. If promotion is a goal of the site it gives a very, very bad impression to outsiders.</p>
<p>Grant<br>
</p>
<div class="gmail_quote">On Jan 19, 2012 4:41 PM, "jim" <<a href="mailto:jim@systemateka.com">jim@systemateka.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<br>
You're wonderful, Ken. Thanks lots. I love<br>
the script.<br>
I guess I'll have to move the <a href="http://sf-lug.org" target="_blank">sf-lug.org</a> web<br>
site to a new host and repoint the domain name.<br>
The current host system is not under my control.<br>
<br>
<br>
<br>
<br>
On Thu, 2012-01-19 at 16:21 -0800, Ken Shaffer wrote:<br>
> Hi Jim,<br>
> Here's a little script to generate the meetings for a year in your<br>
> existing format:<br>
> $ cat sflug-meetings.sh<br>
> #!/bin/bash<br>
> # SF Linux User Group Meetings on the first Sunday<br>
> # and third Monday of the month.<br>
> # Optional parameter is the four digit year<br>
> #<br>
> # Constants for date's day of week<br>
> MONDAY=1<br>
> SUNDAY=7<br>
> # Initialize counters for days and months, and day counters<br>
> MON=1<br>
> DAY=1<br>
> # Targets for meetings, first Sunday and third Monday of a month<br>
> # Algorithm only valid up to the third occurrence of any day<br>
> FIRSTSUN=1<br>
> THIRDMON=3<br>
> NTHSUN=$FIRSTSUN<br>
> NTHMON=$THIRDMON<br>
> # Current year will be used if no input parameter<br>
> CURRENTYR=`date "+%Y"`<br>
> YEAR=${1:-$CURRENTYR}<br>
><br>
> # loop though all months, and sufficient days to get to third Monday<br>
> while [ "$MON" -le 12 ] ; do<br>
> # Use 28 to allow up the the fourth occurrence of any day<br>
> while [ $DAY -le 21 ] ; do<br>
> TST=`date '+%u' -d "$MON/$DAY/$YEAR"`<br>
> if [ $NTHSUN -ge 1 -a $TST -eq $SUNDAY ]; then<br>
> NTHSUN=`expr $NTHSUN - 1 `<br>
> echo "`date -d $MON/$DAY/$YEAR "+%A, %B %e, %Y,"` from 11:00AM<br>
> till 1:00PM"<br>
> fi<br>
> if [ $NTHMON -ge 1 -a $TST -eq $MONDAY ]; then<br>
> NTHMON=`expr $NTHMON - 1 `<br>
> if [ $NTHMON -eq 0 ]; then<br>
> echo "`date -d $MON/$DAY/$YEAR "+%A, %B %e, %Y,"` from 6:00PM<br>
> till 8:00PM"<br>
> fi<br>
> fi<br>
> DAY=`expr $DAY + 1 `<br>
> done<br>
> DAY=1<br>
> MON=`expr $MON + 1 `<br>
> NTHSUN=$FIRSTSUN<br>
> NTHMON=$THIRDMON<br>
> done<br>
><br>
> $ ./sflug-meetings.sh<br>
> Sunday, January 1, 2012, from 11:00AM till 1:00PM<br>
> Monday, January 16, 2012, from 6:00PM till 8:00PM<br>
> Sunday, February 5, 2012, from 11:00AM till 1:00PM<br>
> Monday, February 20, 2012, from 6:00PM till 8:00PM<br>
> Sunday, March 4, 2012, from 11:00AM till 1:00PM<br>
> Monday, March 19, 2012, from 6:00PM till 8:00PM<br>
> Sunday, April 1, 2012, from 11:00AM till 1:00PM<br>
> Monday, April 16, 2012, from 6:00PM till 8:00PM<br>
> Sunday, May 6, 2012, from 11:00AM till 1:00PM<br>
> Monday, May 21, 2012, from 6:00PM till 8:00PM<br>
> Sunday, June 3, 2012, from 11:00AM till 1:00PM<br>
> Monday, June 18, 2012, from 6:00PM till 8:00PM<br>
> Sunday, July 1, 2012, from 11:00AM till 1:00PM<br>
> Monday, July 16, 2012, from 6:00PM till 8:00PM<br>
> Sunday, August 5, 2012, from 11:00AM till 1:00PM<br>
> Monday, August 20, 2012, from 6:00PM till 8:00PM<br>
> Sunday, September 2, 2012, from 11:00AM till 1:00PM<br>
> Monday, September 17, 2012, from 6:00PM till 8:00PM<br>
> Sunday, October 7, 2012, from 11:00AM till 1:00PM<br>
> Monday, October 15, 2012, from 6:00PM till 8:00PM<br>
> Sunday, November 4, 2012, from 11:00AM till 1:00PM<br>
> Monday, November 19, 2012, from 6:00PM till 8:00PM<br>
> Sunday, December 2, 2012, from 11:00AM till 1:00PM<br>
> Monday, December 17, 2012, from 6:00PM till 8:00PM<br>
><br>
> Ken<br>
><br>
> On Thu, Jan 19, 2012 at 7:20 AM, jim <<a href="mailto:jim@systemateka.com">jim@systemateka.com</a>> wrote:<br>
><br>
><br>
> Thank you, Rick.<br>
><br>
><br>
><br>
> On Wed, 2012-01-18 at 22:32 -0800, Rick Moen wrote:<br>
> > Forwarding to a wider audience, as y'all still ought to fix<br>
> it.<br>
> ><br>
> > ----- Forwarded message from Rick Moen <<a href="mailto:rick@linuxmafia.com">rick@linuxmafia.com</a>><br>
> -----<br>
> ><br>
> > Date: Tue, 5 Jul 2011 01:12:27 -0700<br>
> > From: Rick Moen <<a href="mailto:rick@linuxmafia.com">rick@linuxmafia.com</a>><br>
> > To: Jim Stockford <<a href="mailto:jim@well.com">jim@well.com</a>><br>
> > Subject: SF-LUG pages<br>
> > Organization: If you lived here, you'd be $HOME already.<br>
> ><br>
> > Hi, Jim. I notice that <a href="http://www.sf-lug.org/" target="_blank">http://www.sf-lug.org/</a> no longer<br>
> serves up the<br>
> > site 'index.html' page, but rather an HTTPd-generated index<br>
> page.<br>
> > I am unclear on precisely what changed, but suspect you<br>
> should figure<br>
> > that out and fix it. Otherwise, people are not going to<br>
> easily find the<br>
> > front page, currently visible only if you go specifically<br>
> to:<br>
> ><br>
> > <a href="http://www.sf-lug.org/index.html" target="_blank">http://www.sf-lug.org/index.html</a><br>
> ><br>
> > (If you have time, you might want to update what the 'next'<br>
> meetings<br>
> > are. I'm very sympathetic to the problem of deferred<br>
> maintenance.)<br>
> ><br>
> ><br>
> ><br>
> > ----- End forwarded message -----<br>
> ><br>
> > _______________________________________________<br>
> > sf-lug mailing list<br>
> > <a href="mailto:sf-lug@linuxmafia.com">sf-lug@linuxmafia.com</a><br>
> > <a href="http://linuxmafia.com/mailman/listinfo/sf-lug" target="_blank">http://linuxmafia.com/mailman/listinfo/sf-lug</a><br>
> > Information about SF-LUG is at <a href="http://www.sf-lug.org/" target="_blank">http://www.sf-lug.org/</a><br>
><br>
><br>
><br>
> _______________________________________________<br>
> sf-lug mailing list<br>
> <a href="mailto:sf-lug@linuxmafia.com">sf-lug@linuxmafia.com</a><br>
> <a href="http://linuxmafia.com/mailman/listinfo/sf-lug" target="_blank">http://linuxmafia.com/mailman/listinfo/sf-lug</a><br>
> Information about SF-LUG is at <a href="http://www.sf-lug.org/" target="_blank">http://www.sf-lug.org/</a><br>
><br>
><br>
<br>
<br>
<br>
_______________________________________________<br>
sf-lug mailing list<br>
<a href="mailto:sf-lug@linuxmafia.com">sf-lug@linuxmafia.com</a><br>
<a href="http://linuxmafia.com/mailman/listinfo/sf-lug" target="_blank">http://linuxmafia.com/mailman/listinfo/sf-lug</a><br>
Information about SF-LUG is at <a href="http://www.sf-lug.org/" target="_blank">http://www.sf-lug.org/</a><br>
</blockquote></div>