On Tue, 17 Sep 2013, Kevin, Natalia, Stacey and Rochelle wrote:

I am trying to find how to make RDAirPlay start playing once it starts up,
like after a reboot, or a return of power (in the middle of the night).

Here's a Perl script I use to do it. My logs are named Sunday, Monday, Tuesday, etc. but you cn easily modify it for your log naming convention.

Rob

#!/usr/bin/perl

# ==>        START rdairplay WITH TODAY'S LOG

sub getdate {
  @a = localtime($_[0]);
  $wday = $a[6];
  $day = ('00','01','02','03','04','05','06','07','08','09',
          '10','11','12','13','14','15','16','17','18','19',
          '20','21','22','23','24','25','26','27','28','29',
          '30','31')[$a[3]];
  $month = ('01','02','03','04','05','06','07','08','09',
            '10','11','12')[$a[4]];
  $year = substr($a[5],1,2);
  $y = 2000 + $year;
  $m = $month;
  $d = $day;
}


&getdate(time);
$log = ('Sunday','Monday','Tuesday','Wednesday','Thursday',
'Friday','Saturday','Sunday')[$wday];
# $log = $y.'_'.$m.'_'.$d;
`rdairplay --log1=$log:+ &`;
_______________________________________________
Rivendell-dev mailing list
[email protected]
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev

Reply via email to