--- nfo/perl/scripts/giantdisc/bin/gdc.pl 2005/03/08 20:53:46 1.2 +++ nfo/perl/scripts/giantdisc/bin/gdc.pl 2005/03/08 21:07:29 1.4 @@ -22,6 +22,7 @@ use gdclient; my $action = shift; +my $hostname = 'siggi'; sub usage { print "Usage: gdc.pl ripcd|ripstatus", "\n"; @@ -41,14 +42,18 @@ sub ripcd { - gd_connect("siggi"); + gd_connect($hostname); # 1. check if cd is already in database (probably ripped?) - if (my $check_cd = gd_command("chcd", undef, 1)) { - print "-" x 60, "\n"; - print "CD already ripped:", "\n", $check_cd, "\n"; - print "-" x 60, "\n"; + print "-" x 60, "\n"; + print "Check CD: "; + my $check_cd; + if ($check_cd = gd_command("chcd", undef, 1)) { + print "CD already ripped!"; } + print "\n"; + print $check_cd, "\n"; + print "-" x 60, "\n"; # TODO: parse $check_cd and propagate cddb-id to "lcddi", if desired @@ -85,7 +90,7 @@ } sub ripstatus { - gd_connect("siggi"); + gd_connect($hostname); while (1) { my $status_rip = gd_command("grpst", undef, 1);