updated README

This commit is contained in:
John McQuah 2022-03-21 21:36:40 -04:00
parent acd6eb13e2
commit e3d3942dd2
6 changed files with 23 additions and 43 deletions

6
REPO
View File

@ -65,7 +65,6 @@ d:qrupdate
d:libdispatch
d:freepats
d:python3-olefile
d:deadbeef-opus
d:fortune-mod-de
d:python3-leather
d:python3-agate
@ -309,9 +308,6 @@ f:171a3b067aa2d35a435ee2d37df065d4:freepats/.footprint
f:0c09a89ece37d0b1bf450d836e1998e0:python3-olefile/.signature
f:07e1d9975df180ff5b3fe6c66041d7c3:python3-olefile/Pkgfile
f:8a65e413efd9d4e6d1a50e7c2b16ba72:python3-olefile/.footprint
f:cb57ff9140648137a27d4eae3352fb81:deadbeef-opus/.signature
f:801ce3ede362413491c28b9c10d5edc6:deadbeef-opus/Pkgfile
f:b1f59452af918cb91d507e0761e3f75e:deadbeef-opus/.footprint
f:0e86b5c3a2d2ec1a745fcdae99b6ec1c:fortune-mod-de/README
f:02920424681d70954c845b484da43b66:fortune-mod-de/.signature
f:de08a73c18f9770223b71357cc6657e4:fortune-mod-de/Pkgfile
@ -336,7 +332,7 @@ f:c771644583d5eeae51bb7db6e19cf81f:deadbeef-alarm/.signature
f:cc0fb01dffe503647857a6d1d511cb2c:deadbeef-alarm/Pkgfile
f:692f2435b0ffafa4d3014a1d56d8fdc7:deadbeef-alarm/Makefile
f:a33f8fd6cd3eac9152dcde6f1cb6fb87:deadbeef-alarm/.footprint
f:6d075fe426dfedbfd0578bc1cb888a4c:deadbeef-alarm/alarm.cc
f:33b8905efc2f40a3914a6375acf82580:deadbeef-alarm/alarm.cc
f:22142d28d20c3d7a0ac148c877271075:oksh/.signature
f:88d321b08d3354e14157b55bd7fe073a:oksh/Pkgfile
f:d75610ef197b7420248d913c319b1d5c:oksh/post-install

View File

@ -8,21 +8,27 @@ Even with its comprehensive set of command-line options, DeaDBeeF is
ultimately a graphical program, in most cases completely unreachable
from the restricted environment in which crontab shell scripts are executed.
The MPRIS plugin[1] does allow some control of the media player from a crontab
script, but because the dbus session bus address is not exported to cron
tasks, this environment variable must be hard-coded in the shell script
you intend to use for activating DeaDBeeF. (Perhaps a hook for pam_xdg.so
could automatically update your shell script after a successful login and
dbus session launch.) Even after surmounting this obstacle, you'll discover
that the MPRIS plugin implements only one method for selecting a particular
file for playback (OpenUri), and to assemble an entire playlist with this
method you would have to parse the metadata of each song to determine how
long the parent process should sleep between successive calls of OpenUri.
script, but because a script executed by cron usually cannot find the dbus session bus
address in its environment, this variable must be hard-coded in the
shell script you intend to use for activating DeaDBeeF. (For a clumsy way to
automate the hard-coding of session bus address, you might add some sed commands
to your window manager's autostart script, overwriting a definition line in the
*activate-DeaDBeeF* script.) Then having surmounting this
obstacle, you'll discover that the MPRIS plugin implements only one method for
selecting a particular file for playback: OpenUri. Even if xdg-mime could be
persuaded that the file extension m3u indicates a filetype audio/x-mpegurl rather
than text/plain (so that the OpenUri argument is not immediately rejected upon
receipt of the dbus message), the MPRIS plugin only implements OpenUri using
the method `deadbeef->plt_add_file2`, while a playlist would require
`deadbeef->plt_load2`. So to assemble an entire playlist using the methods available
in the MPRIS plugin, you would have to parse the metadata of each song to determine
how long the parent process should sleep between successive calls of OpenUri.
**TLDR**: working around the limitations of crontab and MPRIS is more
trouble than building a specialized plugin for alarm clock functionality.
To close the gap between DeaDBeeF and its console-interface counterparts
(moc, mpd, cmus -- all of which *can* be controlled by scripts in a crontab),
this plugin translates the underlying logic of the audacious alarm
this plugin translates the essential components of the audacious alarm
plugin[2] into the DeaDBeeF idiom. The configuration dialog lets you choose
which days of the week the alarm goes off, what time of day, and which
playlist you want loaded. Leaving the playlist field empty (or selecting
@ -37,7 +43,10 @@ list when the alarm goes off.
The following features were present in the audacious alarm plugin, but
have not been implemented here.
- Volume fading from quiet to loud after a fixed time interval. If you need that kind of control, the mixer commands for most audio stacks (ALSA, OSS, Pipewire, Pulseaudio, sndio) work fine when executed within crontab scripts, and you can just leave the DeaDBeeF volume slider at its highest level.
- Volume fading from quiet to loud after a fixed time interval. If you need that kind of
control, all the underlying audio stacks (ALSA, OSS, Pipewire, Pulseaudio, sndio) offer
command-line mixer tools that work fine when executed within crontab scripts, and you
can just leave the DeaDBeeF volume slider at its highest level.
- Stopping the playback after a specified time interval.
(TODO: let the plugin itself turn off repeat mode if that behaviour is
desired, simply by adding a "disable repeat mode" checkbox to the alarm

View File

@ -163,8 +163,8 @@ static DB_misc_t plugin = {
.version_major = 0,
.version_minor = 1,
.id = "alarm",
.name = "DeaDBeeF Alarm Clock",
.descr = "start playback at a predetermined time",
.name = "Alarm Clock",
.descr = "load a playlist and start the music at a predetermined time",
.copyright = "Copyright (C) 2022 John McQuah <jmcquah@disroot.org>\n"
"\n"
"This program is free software; you can redistribute it and/or\n"

View File

@ -1,4 +0,0 @@
drwxr-xr-x root/root usr/
drwxr-xr-x root/root usr/lib/
drwxr-xr-x root/root usr/lib/deadbeef/
-rwxr-xr-x root/root usr/lib/deadbeef/opus.so

View File

@ -1,4 +0,0 @@
untrusted comment: verify with /etc/ports/jmq.pub
RWTTPlFarK9CxL3acc0uPtnDWaSB8LDN+wuSrF6EXdGKLJT0JVofyI+NAyKlEkSNlOHzcAn9aDmMesoqQjMMOvBemsAggF8nYgI=
SHA256 (Pkgfile) = 922a2a13a8299ef7063946c2232f1c79890f6f36164edf63b846ef91b24356ed
SHA256 (deadbeef-opus-0.8.tar.bz2) = ade79c92a10ae2a181f569bc629481323e5603b2fcf9f34e21deefd45aae4bb8

View File

@ -1,17 +0,0 @@
# Description: opus input plugin for the deadbeef audio player
# URL: https://bitbucket.org/Lithopsian/deadbeef-opus/
# Maintainer: John McQuah, jmcquah at disroot dot org
# Depends on: opusfile deadbeef
name=deadbeef-opus
version=0.8
release=1
source=(https://bitbucket.org/Lithopsian/$name/get/v$version.tar.bz2)
renames=($name-$version.tar.bz2)
build() {
cd *-$name-*
make PREFIX=/usr
mkdir -p $PKG/usr/lib/deadbeef
install -m 0755 opus.so $PKG/usr/lib/deadbeef
}