source: gutenbach/debian/lib/sipbmp3-get-config @ 32b323f

debianmacno-cupsnodebathenaweb
Last change on this file since 32b323f was 32b323f, checked in by Jessica B. Hamrick <jhamrick@…>, 14 years ago

Expand configurability and improve defaults

  • default zephyr class to sipb-test
  • autodetect hostname
  • allow the ALSA channel to be configured
  • Property mode set to 100755
File size: 579 bytes
Line 
1#!/usr/athena/bin/perl
2use strict;
3# Get configuration of sipbmp3
4
5my $zephyr_class = "sipb-test";
6my $host = `hostname`;
7my $queue = "sipbmp3";
8my $channel = "Headphone";
9
10# Configuration
11my $config_file = "/etc/sipbmp3-filter-config.pl";
12if (-r $config_file) {
13    # Inline the configuration file
14    local $/;
15    my $fh;
16    open $fh, $config_file;
17    eval <$fh>;
18}
19
20my %config = (
21    'zephyr-class' => $zephyr_class,
22    'host' => $host,
23    'queue' => $queue,
24    'channel' => $channel,
25);
26
27foreach my $argv (@ARGV)
28{
29    #print $argv . "\n";
30    print $config{$argv};
31}
Note: See TracBrowser for help on using the repository browser.