GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
flickrer - automatic Flickr uploading
by lhl (GPL | Major | Perl | Web)
Here's a script I've been using for the past couple of weeks since I started really using Flickr.
Requires:
File::Basename
File::Copy
LWP::UserAgent
Flickr::Upload
Should be an easy breezy install w/ CPAN (perl -MPCAN -e shell)
flickrer first checks that it isn't already running via a process search, then looks the files from the dropbox and locks (via . rename) while uploading. This makes it pretty safe to run at regular intervals via cron. Once it finishes it moves the file to the sentbox. I run sips, OS X's built in image processing utility to reduce the size of the images, as even w/ a Pro account (1GB/mo), u/ling full photo files would be quickly pass quota.
record - a simple recording script for your Mac
by lhl (GPL | Major | OS X | Shell | Unix)
Written originally for OSCON 2002, this is a simple record script that I wrote for my Mac (and my home-built headphone-embedded binaural microphone). I recently updated this to make sure that it still works (it does), although honestly, if you have an iPod, I recommend picking up a Griffin iTalk, it's great.
Still, this is a handy script to have in your ~bin just in case.
I recommend using Fink to install esdrec and lame:
sudo fink install esound
sudo fink install lame
TODO: switch modify encoding paramaters?
CRM114 Mail.app Training Scripts
by lhl (AppleScript | CRM114 | GPL | Mail | Mail.app | Major)
At the beginning of this year, I knew I needed a new Spam filtering solution and switched to a getmail (much better than fetchmail) and more robust Procmail setup, running CRM114, an advanced learning filter based on alien space technology (well, more accurately, math beyond my ken).
Full setup information belongs in the scope of another site, but I also wrote some AppleScripts to make training much easier w/ Apple's Mail.app
I've included the earlier manual training scripts, as well as the subsequent 'smart' training script that I continue to use today. I suspect I'll continue using this until I switch to a fully automated, web/db-based TUNE method.
include.py - Trac Macro
by lhl (GPL | Python | Trac)
Inserts the output of an external URL.
Example:
[[include(http://www.example.com/)]]
Ver: 0.7.1+
hiptop.pl - Sidekick Address Exporter 0.2.1
by lhl (GPL | Major | Perl | Unix)
Written last winter, this is the Mechanize script I used to dump my T-Mobile Sidekick's (Danger Hiptop) Address Book into an iCal compatible format.
It's quite unfinished, and possibly not working anymore (if the site's changed). But in case there's still (for shame, Danger, for shame) not any syncing software available, this is a good starting point.
Originally posted on the Danger Forums here.
SkipList.js - A JS Skip List Class
by lhl (GPL | JavaScript | Major | Web)
Now, you might be saying to yourself, "Ahh, a skip list, one of my favorite data structures!" However, much more likely, you're probably wondering WTF a skip list (NIST reference) is.
A skip list is a randomized variant of an ordrered linked list with additional, parallel lists.
This is a probabilistic alternative to balanced trees that in general practice gives O(log n) searching w/ easy inserts and deletions (no tree reshuffling).
This OOP JavaScript implementation was created almost entirely from Pugh's original publication, Skip Lists: A Probabilistic Alternative to Balanced Trees.
get_bw.pl v1.0
by lhl (Bandwidth | get_bw.pl | GPL | Major | Monitoring | ServerMatrix)
This is the first public release of a little script I wrote the other month for those using The Planet or ServerMatrix as their ISP that logs into the Orbit system and outputs bandwidth used to the console, and their router-based RRD graph to a pre-determined location.
I have it running on the cron (piping output to a text file) and then pick it up locally w/ GeekTool on my desktop.
muffins bw:
509.3GB, 42.4%
Code licensed under the GPL.