I wrote this script in response to the MPAA's decision to start finding people sharing files, and hassling their ISP to try to get their service disconnected. I know that many people here probably don't agree with file sharing in general, or perhaps some may think it is rather dispicable to not share files in return with the other members of the file-sharing communities, but I personally only use Kazaa Lite occasionally to download MP3s or VHS captures of movies I already own (which is arguably legal under the Fair Use Act), and I feel no obligation to continue sharing the files with the rest of the world after I have them.
So, I just let this run in the background while I am running Kazaa Lite. I'd like to extend it at some point to sort files by type, or maybe even try and get clever and have it guess whether it's a Los Lobos song and create a directory for it or whatnot. Probably not, though. I've been a busy boy lately.
# c:\perl\lib\MyService.pl use strict; use warnings; use File::Copy; my $dir = "C:\\Program Files\\Kazaa Lite\\My Shared Folder"; my $dest = "C:\\incoming"; while (1) { opendir(DIR,$dir) || die "can't opendir $dir: $!"; while(my $file = readdir(DIR)) { if ($file=~/\.dat$/i) { my $i = '1'; } else { move ("$dir\\$file", "$dest\\$file"); } } sleep(3); closedir DIR; }
P.S. This is running on a Windows 98 computer, but it can be converted to run as a service under NT/2000 by following this handy guide. I know it's not that hard of a script to write, but maybe someone else out there can use it.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Kazaa Lite Companion
by mjeaton (Hermit) on Jul 18, 2002 at 12:44 UTC | |
by Dragonfly (Priest) on Jul 18, 2002 at 23:08 UTC | |
by mjeaton (Hermit) on Jul 19, 2002 at 00:05 UTC | |
|
Re: Kazaa Lite Companion
by treefr0g (Novice) on Jul 20, 2002 at 18:33 UTC | |
by Dragonfly (Priest) on Jul 24, 2002 at 18:59 UTC | |
|
Re: Kazaa Lite Companion
by Sifmole (Chaplain) on Jul 19, 2002 at 11:50 UTC | |
by Dragonfly (Priest) on Jul 22, 2002 at 13:20 UTC |