Changeset 26096a5


Ignore:
Timestamp:
Jul 5, 2010, 3:31:36 PM (14 years ago)
Author:
Jessica B. Hamrick <jhamrick@…>
Branches:
debian
Children:
31d7856
Parents:
af9ecf8 (diff), c5a98db (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
git-author:
Jessica B. Hamrick <jhamrick@…> (07/05/10 15:31:36)
git-committer:
Jessica B. Hamrick <jhamrick@…> (07/05/10 15:31:36)
Message:

Merge branch 'master' into debian

Files:
29 added
6 edited

Legend:

Unmodified
Added
Removed
  • README

    rccc050e r03e2535  
    66instance as they would any other document!
    77
    8 The current repositories for various Gutenbach features are:
    9     - gutenbach
    10     - gutenbach-queue
    11     - gutenbach-remctl
    12     - gutenbach-rhythmbox-plugin
    13     - gutenbach-itunes-plugin
    14     - gutenbach-web
     8The current Gutenbach features are:
     9    - the Gutenbach server (packaged as gutenbach-server)
     10    - a terminal queue display (packaged as gutenbach-queue)
     11    - remctl bindings (packaged as gutenbach-remctl)
     12    - client-side scripts to print to, list, and delete from
     13      queues (packaged as gutenbach-client)
     14    - a Rhythmbox plugin
     15    - iTunes plugins
     16    - a webapp interface
    1517
    1618All of these are located on GitHub:
    17 http://github.com/search?langOverride=&q=gutenbach&repo=&start_value=1&type=Repositories
     19http://github.com/jhamrick/gutenbach
    1820
    19 Additionally, see README.old for how Gutenbach /used/ to be installed.
    20 This can sometimes offer insight into how to fix things that are
    21 broken.
     21In terms of how the repository is structured: after discussing the
     22possibility of supporting multiple systems, we decided it would be
     23best to merge everything platform unspecific into the master branch,
     24and then keep separate branches for each other system; e.g. at the
     25moment we have the debian branch, which should be the same as the
     26master branch except that it also contains a debian/ directory.  Now,
     27this means that you should never edit platform-unspecific files in the
     28debian directory; they should *always* be edited from the master
     29branch.  The debian branch should never be merged into the master
     30branch; merging should *always* happen the other way around.
    2231
    23 Questions or comments should be directed at gutenbach@mit.edu
     32See README.old for how Gutenbach /used/ to be installed.  This can
     33sometimes offer insight into how to fix things that are broken.
     34
     35Questions or comments should be directed at gutenbach AT mit DOT edu.
    2436
    2537NOTES:
     
    3244      bt_audio_service_open: connect() failed: Connection refused (111)
    3345
    34   This is because you have alsa configured for bluetooth, but bluetooth is not
    35   enabled.  You should either enable bluetooth, or uninstall the bluez-alsa
    36   package.
     46  This is because you have alsa configured for bluetooth, but
     47  bluetooth is not enabled.  You should either enable bluetooth, or
     48  uninstall the bluez-alsa package.
    3749
    38 - To print to a machine without keytabs, you need to do:
     50- The commands to print and remove jobs should be used via the scripts
     51  in gutenbach-client package.  However, if you insist on using them,
     52  the correct syntax is:
     53     
     54      CUPS_SERVER=servername lp -dqueuename foo.mp3
     55      CUPS_SERVER=servername cancel [ID|-a] queuename
    3956
    40      lpr -Pprintername -Hhostname $file
     57TODO:
    4158
    42   The old `lpr -Pprintername@hostname $file` syntax will no longer work.
    43 
    44 TODO:
    4559- include mixer and channel in debconf, or even better, move it to
    4660  gutenbach-remctl and implement debconf in that package
    4761
    48 - the filter should die and send an error message if it can't find the
    49   config file, not use defaults
    50 
    51 - this should really not conflict with pulse (the biggest problem at the moment is that
    52   pulse will spew a bunch of errors like "Home directory /var/spool/cups/tmp not ours." I
    53   can't figure out how to get rid of them, but they're really annoying.  As long as pulse
    54   is in system mode, things seem to work otherwise.)
     62- this should really not conflict with pulse (the biggest problem at
     63  the moment is that pulse will spew a bunch of errors like "Home
     64  directory /var/spool/cups/tmp not ours." I can't figure out how to
     65  get rid of them, but they're really annoying.  As long as pulse is
     66  in system mode, things seem to work otherwise.)
    5567
    5668- CUPS issues
    57     * the CUPS daemon processes do not inherit groups from the lp user (so, for example,
    58       even if we add 'lp' to 'audio', the process will not be running in group 'audio').
    59       For the time being, I've set the CUPS daemon to always run under group 'audio',
    60       but there should really be a better solution.
    61     * debathena printer configuration defaults to using ipp, e.g.:
    62        jhamrick@lemon-meringue:~$ lpstat -v sipbmp3
    63        device for sipbmp3: ipp://zsr.mit.edu:631/printers/sipbmp3
    64      so you can't just do `lpq -Psipbmp3`, you have to use `lpq -Psipbmp3 -hzsr` or
    65      something similar.  Same thing goes with lprm.  It is interesting that this is
    66      only the case with lpq and lprm, though, and lpr Just Works.  This shouldn't be
    67      an issue on non-debathena machines.
    6869
    69 - Create wrapper scripts for queuing/dequeuing jobs?  Making it easier to use across
    70   multiple platforms, regardless of debathena/normal linux/etc?
     70    * the CUPS daemon processes do not inherit groups from the lp user
     71      (so, for example, even if we add 'lp' to 'audio', the process
     72      will not be running in group 'audio').  For the time being, I've
     73      set the CUPS daemon to always run under group 'audio', but there
     74      should really be a better solution.
     75
     76    * when the Purge-Jobs command is sent, the jobs are removed, but
     77      the current mplayer instance continues playing.  This
     78      unfortunately leads to jobs being played over each other when
     79      the CUPS server restarts
     80
     81- Making it easier to use across multiple platforms, regardless of
     82  debathena/normal linux/etc?
     83
     84- Gutenbach should not depend on Debathena -- ideally,
     85  gutenbach-server should be debathena free, and then if people want
     86  to use zephyr, etc., they can install an additional gutenbach-zephyr
     87  package or something
     88
     89- add regex support to the client scripts, so you can do something
     90  like `gbr sipbmp3 *.mp3` and have it send separate jobs to the queue
     91
     92- add client scripts for the remctl package, something maybe like
     93  `gbvol [set|get] number`.  Or maybe just leave it with using remctl.
     94
     95- fix the web interface
     96
     97- fix the youtube feature.  Additionally, make it possible to play
     98  movies!
  • client/bin/gbr

    r611bd26 rc5a98db  
    3131}
    3232
    33 my @args = ("CUPS_SERVER=$host", "lp", "-d$queue", "$file");
    34 exec (@args) or die "Couldn't execute lp command";
     33$ENV{CUPS_SERVER}="$host";
     34
     35if ($file =~ m|http://www\.youtube\.com/watch\?v=|) {
     36    open(LP, "|-", "lp", "-d$queue");
     37    print LP "$file";
     38    close LP;
     39}
     40else {
     41    my @args = ("lp", "-d$queue", "$file");
     42    exec (@args) or die "Couldn't execute lp command";
     43}
  • client/bin/gbr.1

    r2c76f34 rc5a98db  
    77.SH DESCRIPTION
    88Prints a file to a Gutenbach queue, given the queue name and the path
    9 to the file.  The Gutenbach queue must have previously been added with
     9to the file.  The path may also be a URL to a
     10.B YouTube
     11video (e.g. http://www.youtube.com/watch?v=foo).  The Gutenbach queue
     12must have previously been added with
    1013.B gutenbach-client-config
    1114so that gbr knows which host to use.
  • client/bin/gbrm

    r611bd26 rc5a98db  
    3434
    3535if ($id eq "all") {
    36     @args = ("CUPS_SERVER=$host", "cancel", "-a", "$queue");
     36    @args = ("cancel", "-a", "$queue");
    3737}
    3838else {
    39     @args = ("CUPS_SERVER=$host", "cancel", "$id", "$queue");
     39    @args = ("cancel", "$id", "$queue");
    4040}
     41$ENV{CUPS_SERVER}="$host";
    4142exec (@args) or die "Couldn't execute cancel command";
  • server/lib/gutenbach

    r30beeab rc5a98db  
    164164    # YouTube URLs are resolved by the youtube-dl command.
    165165    # Launch youtube-dl
    166     open(YTDL, "-|", "youtube-dl", "-g", $filepath) or die "Unable to invoke youtube-dl";
    167     # Read the title (currently not doing so because youtube-dl doesn't know how to get the title.
    168     my $title = ""; # <YTDL>
     166    $pid = open(YTDL, "-|");
     167    if ($pid) {
     168        print ZEPHYR "YouTube video $filepath.\nCurrently downloading, please wait...";
     169        close ZEPHYR;
     170        while (<YTDL>) {
     171            open(ZEPHYR, "|-", @zwrite_command);
     172            print ZEPHYR $_;
     173            close ZEPHYR;
     174        }
     175        open(ZEPHYR, "|-", @zwrite_command);
     176        print ZEPHYR "Done downloading.";
     177        close ZEPHYR;
     178    }
     179    else {
     180        my @args = ("youtube-dl", "-q", "-o", "/tmp/youtube.flv", $filepath);
     181        exec(@args) or die "Couldn't exec youtube-dl";
     182    }
     183
     184    $filepath = "/tmp/youtube.flv";
    169185    # Print the title to zephyr and the status string.
    170     print ZEPHYR "YouTube video $filepath\n$title";
    171     $status .= " YouTube video $filepath. $title.";
    172     # youtube-dl prints the URL of the flash video, which we pass to mplayer as a filename.
    173     $filepath = <YTDL>;
    174     chomp $filepath;
    175186  } else { # Doesn't appear to be a YouTube URL.
    176187    print STDERR "Resolved external reference to $filepath\n";
     
    253264    if (/^([^#]\S+)/) {
    254265      printf (STDERR "Found playlist line: %s\n", $_);
    255       open(LPR, "|-", 'lpr', '-P'.$queue.'@localhost', '-#', '42', '-J', $arguments->{"job-title"}, '-o', 'job-priority=100');
    256       print LPR $1;
    257       close(LPR);
     266      $ENV{CUPS_SERVER}='localhost';
     267      open(LP, "|-", "lp", "-d", "$queue", "-n", "42"); #'-#', '42', '-J', $arguments->{"job-title"}, '-o', 'job-priority=100');
     268      print LP $1;
     269      close(LP);
    258270      $i++;
    259271    }
     
    327339
    328340    my @args = (qw|/usr/bin/mplayer -vo fbdev2 -zoom -x 1024 -y 768 -framedrop -nolirc -cache 512 -ao alsa -really-quiet |, $filepath);
    329     #print STDERR "About to exec: ", Dumper([@args]);
     341    #pint STDERR "About to exec: ", Dumper([@args]);
    330342    exec(@args) ||
    331343      die "Couldn't exec";
  • .gitignore

    r323f614 r1d7e681  
    11*~
     2debian/files
     3debian/*.debhelper
     4debian/*.substvars
     5debian/*.debhelper.log
     6debian/gutenbach/
     7debian/gutenbach-client/
     8debian/gutenbach-queue/
     9debian/gutenbach-remctl/
     10debian/gutenbach-server/
     11debian/stamp-makefile-build
     12debian/tmp/
    213client/bin/*.1.gz
Note: See TracChangeset for help on using the changeset viewer.