Ok, good luck with your project! Romain
2013/5/31 Ashworth Payne <email.ashwo...@gmail.com>: > Hello list, > > Please don't waste any time on this. I changed to: > > ret = get_process_lines("/usr/bin/sqlite3 -separator \' \' auth.db \'select > * from deejays where user=\"#{user}\"\'") > > Now the script will run, but auth attempts cause sqlite to error. I'll keep > plugging away at it, i'm sure I'll figure it out. > > Thanks > > > On Fri, May 31, 2013 at 10:36 AM, Ashworth Payne <email.ashwo...@gmail.com> > wrote: >> >> I'm using the example auth to attempt sqlite auth...the script is simple >> since i'm learning-as-i-go.... >> >> I'm hung-up on a problem where ls complains: >> Line 17, char 8 before "=": Parse error! >> the line is: >> ret = list.hd(ret) >> >> Here is the full test-script... its probably something really simple that >> i'm overlooking. Thanks for your time. >> >> #!/usr/bin/liquidsoap >> >> >> ################################################################################ >> # Log dir >> set("log.file.path","/tmp/basic-radio.log") >> def auth(user,password) = >> # Call an external process to check >> # the credentials: >> # The script will return the string >> # "true" of "false" >> # >> # First call the script >> ret = get_process_lines("/usr/bin/sqlite3 -separator ' ' auth.db 'select >> * from deejays where user="#{user}"'") >> >> # from example on ls site... --user=#{user} --password=#{password}") >> # Then get the first line of its output >> ret = list.hd(ret) >> # Finally returns the boolean represented >> # by the output (bool_of_string can also >> # be used) >> if ret == "true" then >> true >> else >> false >> end >> end >> >> >> >> >> >> >> ################################################################################ >> files = single("/mnt/some/noise.mp3") >> >> ################################################################################ >> # Lets build a harbor... >> set("harbor.bind_addr","0.0.0.0") >> dj_harbor = >> input.harbor("/",auth=auth,port=6846,icy=true,buffer=30.,max=60.) >> >> ################################################################################ >> radio = fallback(track_sensitive=false, >> [dj_harbor,files]) >> >> >> ################################################################################ >> #Playout to Alsa on first soundcard hw:0,0 and enjoy crackles :) >> output.alsa(fallible=true,device="hw:0,0",radio) >> >> ################################################################################ >> >> >> > > > ------------------------------------------------------------------------------ > Get 100% visibility into Java/.NET code with AppDynamics Lite > It's a free troubleshooting tool designed for production > Get down to code-level detail for bottlenecks, with <2% overhead. > Download for free and get started troubleshooting in minutes. > http://p.sf.net/sfu/appdyn_d2d_ap2 > _______________________________________________ > Savonet-users mailing list > Savonet-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/savonet-users > ------------------------------------------------------------------------------ How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j _______________________________________________ Savonet-users mailing list Savonet-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/savonet-users