Article View: comp.sys.sun
Article #9371Checking .monthtool from a dumb tty
From: Andy Malis
Date: Sat, 03 Dec 1988 02:15
Date: Sat, 03 Dec 1988 02:15
23 lines
1181 bytes
1181 bytes
This is for monthtool users:
The following short shell script, which I call "today", prints out today's
appointments from your ~/.monthtool file.
You can use it from any dumb tty or tty window, or use it from an "at"
script to send you mail in the morning listing your appointments for the
day. It understands regular weekly appointments.
Andy
=======cut here=======
#!/bin/csh -f
set a=( `date '+%m %d %y'` )
@ b=$a[1]
@ c=$a[2]
@ d=$a[3]
@ e=`date +%w` + 1
set f="^${b},${c},..${d},|^99,${e},0,"
egrep $f ~/.monthtool | sed -e "s/^[0-9]*,[0-9]*,[0-9]*,//" \
-e "s/,/ /" -e "s/^ *//" \
-e "s/^\([0-9][0-9]\)\([0-9][0-9] \)/\1:\2/"
=======that's it=======
Technical Details
Message-ID:
<8811221402.AA28940@rice.edu>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!watmath!clyde!att!rutgers!mailrus!cornell!uw-beaver!rice!sun-spots-requestShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watmath!clyde!att!rutgers!mailrus!cornell!uw-beaver!rice!sun-spots-request From: malis@cc5.bbn.com (Andy Malis) Newsgroups: comp.sys.sun Subject: Checking .monthtool from a dumb tty Message-ID: <8811221402.AA28940@rice.edu> Date: 3 Dec 88 02:15:35 GMT Sender: usenet@rice.edu Organization: Rice University, Houston, Texas Lines: 23 Approved: Sun-Spots@rice.edu Original-Date: Tue, 22 Nov 88 08:59:19 -0500 X-Sun-Spots-Digest: Volume 7, Issue 34, message 10 of 12