1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611
|
release names: The sluis in maas, ceramique eettent
Цер Cer mountain
Petkovica monastery
Čokešina monastery + village
Prnjavor village
Novo Celo village
Lešnica village + river
Jadar river
----
test 'draai insert': file-as-arg-mode borken, probably since draai version 20100511, when it
was implemented. (implemented succesful 'file on stdin'-mode)
joostvb@arrr:~/git/draai% export DR_DEBUG=true
joostvb@arrr:~/git/draai% draai insert 'LOCAL/201308/Various/Alan_Lomax_Collection_-_Bahamas_1935_Vol_2_-_Ring_Games_and_Round_Dances/22-Nassau_string_band-Delia_Gone.ogg'
this now works:
"draai search 'delia gone' | draai insert"
---
joostvb@sveznalica:~/git/draai% draai --raw list | grep '^22)'
22) http://streams.greenhost.nl:8080/pop: - Popart (do 22 sep 21:00) (Concertzender Pop - )
joostvb@sveznalica:~/git/draai% draai list | grep '()'
22) - Popart (do 22 sep 21:00) ()
86) Radio 5 - ()
89) Radio 2 - ()
108) http://streams.greenhost.nl:8080/jazznotjazz ()
joostvb@sveznalica:~/git/draai% mpc --format "t %title% - f %file% - n %name% - p %position%" playlist | grep -i popart
t Popart (do 22 sep 21:00) - f http://streams.greenhost.nl:8080/pop - n Concertzender Pop - p 21
----
draai inject / draai guestlist should work on both tracknumbers and mpd-files
a bit like mpc findadd, see "searchadd" below.
rc rc items
-----------
test "watch" again
чет 21 07:01 < michiel> zie overigens ook
http://www.acooke.org/cute/TheIdealUs0.html en
https://github.com/andrewcooke/uykfg
чет 21 07:02 < michiel> (mpd playlist generators die een soort van last.fm
database queryen om links tussen obscure muzikanten te
vinden)
------
rc items
--------
- utf8 and http/radio-stations in playlist make draai peek fail: lines too long.
joostvb@arrr:~% draai peek | head -4
[playing] #1/249 2:23/2:48 (85%)
1) Jimi Hendrix - Stockholm Concert second sho...kholm, Sweden) - Fire (2:48)
2) Cumbia Siglo XX - Palenque Palenque: Champe...75-1991 - Naga Pedale (3:27)
3) Joan Baez - Folk Singers Round Harvard Squa...ur Pretty Little Baby (2:31)
joostvb@arrr:~% mpc --format "a %artist% - a %album% - aa %albumartist% - c %composer% - ti %title% - tr %track% - ti %time% - f %file% - p %position%" playlist | grep http
a - a - aa - c - ti - tr - ti - f http://icecast.omroep.nl/radio5-bb-mp3 - p 201
a B92 - a - aa - c - ti Radio B92 - tr - ti - f http://stream.b92.net:7999/radio-b92.ogg - p 206
joostvb@arrr:~% mpc --format "a %artist% - a %album% - aa %albumartist% - c %composer% - ti %title% - tr %track% - ti %time% - f %file% - p %position%" playlist | head -4
a Joan Baez - a Folk Singers Round Harvard Square - aa - c - ti What You Gonna Call Your Pretty Little Baby - tr 06 - ti 2:31 - f USB/Joan_Baez/Folk_Singers_Round_Harvard_Square/06-What_You_Gonna_Call_Your_Pretty_Little_Baby.ogg - p 1
a Jimi Hendrix - a Stockholm Concert second show (January 9, 1969, Konserthuset, Stockholm, Sweden) - aa - c - ti Red House - tr 07 - ti 11:32 - f USB/Jimi_Hendrix/Stockholm_Concert,_second_show/07-Red_House.ogg - p 2
joostvb@sveznalica:~/git/draai% mpc --format "ti %title% - tr %track% - ti %time% - f %file% - n %name% - p %position%" playlist | grep http
ti Kroniek van de Nederlandse muziek (za 6 jun 19:00) - tr - ti - f http://streams.greenhost.nl:8080/raakvlakken - n Concertzender Raakvlakken - p 157
ti - tr - ti - f http://icecast.omroep.nl/radio4-bb-mp3 - n Radio 4 - p 160
ti - tr - ti - f http://streams.greenhost.nl:8080/jazznotjazz - n - p 223
ti - tr - ti - f http://mp3.streampower.be/klara-high - n Klara | kwaliteit *** - p 256
so: %file% and optionally %title% and/or %name%
- report mpc doc bug, see below
- use new (i.e. Debian wheezy) mpd/mpc features (idle, a.o.):
mpc --wait <cmd>
mpc idle
mpc idleloop
mpc crop -> draai crop
mpc prev -> draai previous
mpc random -> draai random
mpc consume -> draai consume
mpc shuffle -> draai shuffle
mpc search ....
mpc search ... | mpc add -> draai searchadd
mpc search ... | mpc inject -> ....
mpc update --wait -> draai update
report bug:
" idle [events]
Waits until an event occurs. Prints a list of event names, one
per line. See the MPD protocol documentation for further infor‐
mation.
"
mpc(1)
protocol spec not shipped with package.
pretty urgent items
-------------------
- Fix buildhelp() in ./setup
revamp: schedule Cambridge hack session
help texts in zsh completion stuff, --help and manpage should use ONE
source. move help stuff to one place; include help/ stuff in configure phase.
See ./setup for current implementation.
Think about lists in zoem, use stijn's trick.
Alternative way to implement this: Run e.g. "draai --raw --help skip",
"draai --raw help" "draai --raw --nice help"
(as of 2008-06, quite some options are only half-implemented)
.
Another alternative way to implement this:
selfdocumenting zoem stuff:
foo=bar
: cat <<EOT
\zoemstart
\zoem stuff
\zoemstop
EOT
blah=duh
man package, -d roff
zoem stuff
\:{
shell meuk
}
zoem stuff
zou dat werken?
another re-implementation plan: this is stupid:
joostvb@sveznalica:~/git/draai% cat help/command/harder
Play louder.
joostvb@sveznalica:~/git/draai% cat help/command/crescendo
Play louder.
help, license, version: should be commands, not options.
draai --help should exit 1 and give usage info.
----------------------------------------------------------------------------
Date: Sun, 30 Nov 2008 23:05:22 +0100
From: Stijn van Dongen <stijn@micans.org>
To: Joost van Baal <joostvb@mdcc.cx>
Subject: zoem mongering
Message-ID: <20081130220521.GA37144@xs4all.nl>
Ha Joost,
zie bijgevoegd *en* geciteerd de file 'lscat.azm' die misschien doet wat je wil.
Roep zoem aan als
zoem -i lscat.azm -allow ls:cat -o -
\: - lees de namen.
\setx{thefiles}{
\inspect{
{mods}{iter-lines,discard-miss}
}{(.*~.bzz)}{_#1{{\1}}}{\system{ls}}
}
\: - maak key-value paren.
\apply{_#1{\!{\setx{%{\1}}{\system{cat}{\1}}}}}{\thefiles}
\: - print een value.
[\%{foo.bzz}]
[\%{bar.bzz}]
\: - print alle key-value paren.
\apply{_#1{\!{[\1]-->[\%{\1}]}}}{\thefiles}
In dit voorbeeld worden de file namen gematcht op een .bzz suffix.
Als je dat niet wilt kun je het patroon (.*) gebruiken (maar ik
raad aan een suffix conventie te gebruiken :-).
Als je vervolgens iets voor alle file namen wil doen, kun je
\apply gebruiken zoals hierboven.
Nog iets: je kunt ls aanroepen met argumenten, bijvoorbeeld zo:
\system{ls}{{-r}{-t}}.
En: \apply expandeert beide argumenten (1e argument: de 'subroutine' key die
iteratief gebruikt wordt op de sub-argumenten in het 2e argument). Dat kan soms
een beetje prutsen zijn om ongewenste evaluatie/expansie te voorkomen. In het
voorbeeld hierboven wordt \!{ } gebruikt om te zorgen dat bepaalde stukken
overgeslagen worden tijden genoemde expansie. In de documentatie heet \!{ }
'delay scope' omdat het 1 expansie stap overslaat. \!!{ } slaat twee stappen
over. En \eval{\eval{\!!{\bar}}} is precies hetzelfde als \bar. Het is de
barre praktijk van macro talen :)
groetjes,
Stijn
----------------------------------------------------------------------------
some items
----------
- fix new author name in manpages copyright: utf8, cyrillic
\set{"man::author"}{Joost van Baal-Ilić <joostvb-draai@mdcc.cx>} . html, roff
is ok, ps (and pdf) borken. once fixed, ship pdf manpages.
INSTALL zsh stuff:
compinit niet genoeg; nodig:
joostvb@hille:~% exec zsh --login
move zsh stuff to README
urgent items
------------
- update this todo-list; lots of obsolete stuff is in it.
- bug: on empty/non-playing playlist, "draai draai" chokes
- README in html, ship .txt too.
- more docs and features for "draai insert": hang deze track net achter de nu spelende
"insert" is "fileguestlist" (as opposed to "trackguestlist", which is
"guestlist")
insert could honor --prio : --prio 2 : after upcoming track.
-
ma 26 12:56 < joostvb> mpc update; mpc idle; mpc add foo
ma 26 12:56 < Fruit> ah zo hm
ma 26 12:57 < Fruit> ik denk dat ik mpc add foo; mpc move $(getlast)
$(getcurrent+1) wil
ma 26 12:57 < Fruit> en dan liefst in één atomaire operatie (dat kan binnen het
mpd-protocol namelijk)
ma 26 12:58 < Fruit> en dat moet uiteraard ook goed gaan als je een directory
toevoegt
ma 26 12:58 < Fruit> dus eerst aantal opvragen, dan toevoegen, dan oude aantal
t/m nieuwe aantal moven
ma 26 12:59 < joostvb> yep
ma 26 12:59 < Fruit> in jouw draai watch scriptje wil je trouwens misschien mpc
idle gebruiken ipv sleep 1
- fade in/out more aggressive: never silence between tracks.
- implement "draai pick":
draai list | grep Camper | draai pick
draai --raw list | grep Camper | draai pick
draai pick > Picking from:
121) Camper van Beethoven - Camper van Beethoven - Lulu Land (2:41)
157) Camper van Beethoven - Camper van Beethoven - We Saw Jerry's Daughter (2:10)
158) Camper van Beethoven - Camper van Beethoven - Good Guys and Bad Guys (3:56)
>159) Camper van Beethoven - Camper van Beethoven - Jo Stalin's Cadillac (2:32)
Pick first matching entry? [Y,2,3...,l,r,q]
(Yes; no, pick 2nd; no, pick 3rd; no, pick last; no, rerun; quit)
Y
You've picked
121) Camper van Beethoven - Camper van Beethoven - Lulu Land (2:41)
Would you like to guestlist this track? [Y,2,3,..,d,u,q]
draai pick>
Yes; no, schedule as 2nd upcoming track; no, schedule as 3rd upcoming track; delete from playlist; unguestlist; quit
pick should honor --silent
- 'draai osjittisstil' update zsh stuff.
- dr_push: it'd be nice if it would mangle files and pathnames to fit on a
vfat filesystem.
- dr_umount would be nice
- add stuff to generate playlist "latest"
- draai second 123 = draai --prio 2 guestlist 123
- make this tool usable for DJ's: more flexible playlist handling, more
fade-in/fade-out features:
+ draai "peek" should accept an arg
draai peek noftracks
+ draai draai should do an "insert": insert these songs just after current
song. implement as "mpc add; mpc move":
old curr old curr old curr
old 1 new 4 new 2
old 2 old 1 new 3
old 3 old 2 ... new 4
new 1 old 3 old 1
new 2 new 1 old 2
new 3 new 2 old 3
new 4 new 3 new 1
- reimplement "tail" using ncurses (or watch(1)?): tail should show "peek" too.
current song in boldface or reverse video
- document "pause" and "resume|unpause|play" commands (mpc pause, mpc play), add
zsh completion
- draai draai should not clear current playlist, but remove all pending songs
but the current one from the current playlist, and append the given
tracks/playlists. This makes for more smooth fade in/out.
- add ui for
mpc search artist Stooges | mpc add
mpc search artist Hendrix | mpc add
- document extra aliases: init: genesis; next: volgende; unguestlist: unfriend,
ontvriend; insert: voegin; skip: slaover; fastforward: voorwaarts; tail:
staart; peek: spiek; play (unpause, resume): ga; quit (exit, stop, pause): ho
items as found while working on eeepc
-------------------------------------
inspect $DISPLAY for draai-init-nox
draai move 34 50 (just like mpc)
draai --terse list
draai --terse --search 'greatest_hits' list : gives 3 6 12 19
tty12 group tty for draai:
root@hille:/etc/udev/rules.d# vi 93-permissions-local.rules
udev / dr-mount
/dev/disk/by-label/PENDRIVE /media/PENDRIVE vfat user,noauto 0 0
watch(1) "cat -v" !?, see http://mdcc.cx/tmp/watch/
joostvb@hille:~% draai unguestlist $( draai --raw list | grep Best_Ever | head | while read n r; do echo $n | sed 's/)//'; done )
> add --match option:
> draai --match greatest_hits delete
> draai --match greatest_hits guestlist
> suggested usage: first run --match with --no-act, to inspect
> what would get matched.
private/local items
-------------------
- radio kink classix: dj@nagy:~% mpg321 http://81.173.3.24/
- see also dj@nagy:etc/zsh/rc.local for radio6 and bbc3
other items
-----------
- add support for smart merging of playlists:
--playlist=foo,1 --playlist=bar,40 --playlist=duh,7
--playlist=foo --playlist=bar is equivalent to
--playlist=foo,1 --playlist=bar,1
--playlist=foo,2 --playlist=bar is equivalent to
--playlist=foo,2 --playlist=bar,1 is equivalent to
--playlist=foo --playlist=foo --playlist=bar
: adding ,N is a shorthand for repeating the arg N times. playlists get
truncated to the size of the smallest one. so, no matter the size of foo
and bar, --playlist=foo,2 --playlist=bar,1 will give you 2 foo-tracks for
every bar-track.
- support voor last.fm audioscrobbling erin. An account at last.fm
is needed to get any services from them.
- support voor last.fm streaming audio erin. shell-fm(1)
shell-fm heeft plugin voor event tijdens wisselen track.
shell-fm is niet eenvoudig om te bouwen tot mpd client.
t heeft wel een socket en netwerk-interface
Wed 27 14:11 <Fruit> http://www.last.fm/user/Fruitje/
An account at last.fm is needed to get any services from them.
dj@nagy:~% shell-fm lastfm://artist/Alexander+von+Schlippenbach/similarartists
dj@nagy:~% shell-fm lastfm://artist/Anthony+Braxton/similarartists
Perhaps zomg is more interesting: ZOMG is a console-based last.fm submission
and radio client written in Z-Shell.
http://hg.debian.org/hg/private/schizo/zomg http://packages.debian.org/zomg
- document (and implement on gelfand): syslog.conf: local? to e.g.
/var/log/draai
- add to contrib:
root@kovalevskaya:/etc/logcheck/ignore.d.server# cat draai
#
#
^\w{3} [ :0-9]{11} [._[:alnum:]-]+ draai\[[0-9]+\]:
- Give examples in documentation:
suggested desktop layout
.----------------.
| logtail .------.
` ------- | tail |
| |
`------'
.------.
| peek |
| |
`------'
and once in a while, press ctrl-alt-F12
startup:
% draai init calls draai tail > /dev/tty12 & (document: dj is a member of group tty)
dj@gelfand:~/mp3% draai -t +30 quit
dj@gelfand:~/mp3% draai -t 08:30 quit
dj@gelfand:~/mp3% draai -p all draai
dj@gelfand:~/mp3% draai tail <- in separate window
dj@gelfand:~/mp3% draai skip
dj@gelfand:~/mp3% draai -t 23:01 -p all draai
dj@gelfand:~/mp3% draai peek
dj@nagy:~% draai delete $(seq 3 65)
zsh: draai delete {12..29}
draai guestlist {50..34}
% repeat 10; do draai skip; done
dj@nagy:~% shell-fm lastfm://artist/This+Heat/similarartists
Air
Biosphere
dj@nagy:~% shell-fm lastfm://artist/Alexander+von+Schlippenbach/similarartists
dj@nagy:~% shell-fm lastfm://artist/Anthony+Braxton/similarartists
- "tail" is buggy:
2007-03-18 21:54:56 Anvil FX - Brazz-Ill - Miolo de Cabeça (4:28)
has borken line length: utf-8 issue, probably.
- implement setup uninstall
- don't use help2man, but something "real" for the manpage (see also
ideas from python era, below) ReST still (2007-03) doesn't seem to be easily
transformed to roff. use zoem? use xml? have zoem run --help and --version?
the last trick _is_ used and documented in some zoem example. zum has e.g.
\verbatim{\system{../src/zoem}{{-l}{session}}}
see aangifte-ib and webalizer-stonesteps manpages for roff example.
- document this
draai draai Lee_Scratch_Perry/Roast_Fish,_Collie_Weed_and_Corn_Bread/ The_Fall/
works: args don't need to be tracks. Also,
draai draai Various/Mind_The_Gap_6{0,1,2}<tab>
works.
Wishlist items
--------------
- don't do "draai --raw tail" but "draai tail --raw", etc.
- perhaps it'd be nice if we could still play local files too:
~$ draai draai /tmp/foo.ogg
- should process .m3u , stdin and command line args;
cat <<EOT | draai draai blah\ blah.ogg
track.ogg
song.mp3
EOT
- should process audiofiles with " and ' in filename. (Space is fine, we've
checked).
- allow for a ~/.draai/rc config file (FHS desktop policy?)
- "tail" could better do:
2007-03-19 07:22:21 Erik Satie - The Early Piano Wor...- Gnossienne No. 1 (5:42)
2007-03-19 07:27:58 Photek - Solaris - Junk (5:28)
instead of:
2007-03-19 07:22:21 Erik Satie - The Early Piano Wor...- Gnossienne No. 1 (5:42)
2007-03-19 07:27:58 Photek - Solaris - Junk (5:28)
- version, help, license should be commands, not options
- enable command "append": append to current playlist
Old ideas, from the pyton era
-----------------------------
- look at python code examples: in /usr/bin/ :
- reportbug's (reportbug, querybts),
- debian-goodies (checkrestart, popbugs)
- linda (Steve Kowalik),
- pydoc,
- tla_load_dirs (John Goerzen)
- document & write manpage
using pydoc
there seems to be no roff output for pydoc: even pydoc's own manpage says:
AUTHOR Moshe Zadka, based on "pydoc ‐‐help"
write a pydoc2zoem thingie?
ReST sucks (am I wrong?), don't use it.
docutils ReST http://docutils.sourceforge.net/ offers a ManPage Writer too.
hrm. smells unstable.
http://docutils.sourceforge.net/sandbox/cben/make/Makefile.docutils <- nice.
Debian package python2.4-docutils /usr/share/doc/python-docutils
rest2xml(1)
pydoc /usr/bin/popbugs
joostvb@nagy:~% pydoc ~/arch/draai/draai/modules/draai.py
help2man ? ->
http://sourceforge.net/mailarchive/message.php?msg_id=9285365
result.append(formatter.format_heading(_("options")))
def format_usage(self, usage):
return _("usage: %s\n") % usage
joostvb@nagy:/usr/lib/python2.4% less optparse.py
joostvb@nagy:~/svn/starship.python.net% svn co svn://starship.python.net/optik/trunk optik
r484 | gward | 2005-01-17 03:22:13 +0100 (Mon, 17 Jan 2005) | 2 lines
Always capitalize "Usage" and "Options" in help output for consistency.
latest release as of Fri Mar 25 12:02:04 CET 2005 is optik 1.5 (2004-12-07 02:04)
1.5.1 is yet to be released.
- check for ogg/mp3 interfaces
python-pyvorbis - A Python interface to the Ogg Vorbis library
1.3-1 Dec 2003 (upstream is dead, latest upstream)
include (part of) ogg123.py ? ogg123.py is GPL-ed, since pyvorbis-1.3 is.
ogg123.py --module=lad file.ogg works (somewhat (for me)). However, it plays
tracks on a much slower pitch...
Use python-id3 and python-pymad for mp3
- make it a mpd client. probably should use:
python-mpdclient - Python interface to MPD (source: py-libmpdclient)
(see also: pygmy, pympd, libmpd-dev, libmpd0)
run: ~% pydoc mpdclient2
libmpd-dev: "This package contains the development libraries, headers and documentation."
no it doesn't: no docs there...
try http://www.musicpd.org/ for docs
Peeksheet
---------
joostvb@nagy:~/arch/draai/draai% DIB_V=$(cat VERSION) DIB_P=draai DIB_TARDIR=. debian-install-build
joostvb@bruhat:~/git/draai% git pull ssh://git/~joostvb/git/draai.git
joostvb@bruhat:~/git/draai/debian% git push ssh://git/~joostvb/git/draai.git joostvb-arch@mdcc.cx--2005-draai,draai--mainline--0.1
|