![]() ![]() Using GNU date, it calculates the day of the year (0-365 or 366 in a leap year) of your deadline. Growlnotify -a "Scrivener" -sticky -message "$DAYSLEFT days left" "Thesis" What it does Change '1 march' to your deadline!ĭUEDATE=`$GNUDATE '+%j' -date '1 march'` ![]() # if you installed coreutils using MacPorts, uncomment the next line # if you installed coreutils using the Rudix installer, uncomment the next line Once you have SleepWatcher installed and working (don't forget about installing the launchd plist and loading it as instructed in the ReadMe.rtf), your personal 'wakeup' script will be kept at ~/.wakeup, and you'll need to add the following lines to it (the #!/bin/sh line should be the very first line of the file, and should only appear once). ![]() Now that we have all of the necessary pieces, we just need to put them to good use. OK, now all of that sounds complicated, but it shouldn't take you more than a few minutes, and once you install all the necessary pieces, you'll be ready to do other cool things with them in the future. Download the regular Growl DMG, mount it and install the growlnotify.pkg from inside the 'Extras' folder. Third, you'll need 'growlnotify' from Growl. (Note that you may need to create /usr/local/sbin/ before installing it: 'sudo mkdir /usr/local/sbin'). Download the file and follow the instructions in the ReadMe.rtf to install it. Second, you'll need SleepWatcher, which is another free program that will automatically run shell scripts whenever your computer goes to sleep or wakes up. Set the GNUDATE variable to the appropriate path below. We're going to be using the GNU version of 'date', which MacPorts puts in /opt/local/bin/gdate and Rudix installs to /usr/local/bin/date. You could install them manually, but if you don't have them already, I suggest getting them either from MacPorts (sudo port install coreutils) or Rudix (if you're not familiar with Rudix, check out our previous coverage). First, make sure you have the GNU Coreutils installed. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |