summaryrefslogtreecommitdiff
path: root/rc/bin/play
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@rei2.9hal>2012-01-22 01:12:28 +0100
committercinap_lenrek <cinap_lenrek@rei2.9hal>2012-01-22 01:12:28 +0100
commit158a3cf4dda6d7d8bb0a8688d58bf267d75041bb (patch)
tree289bbb7ce64ce5d8be411e578ba8614d6441073f /rc/bin/play
parente6507897a1ad87b579b7e20e1aa7c85d6de1c81b (diff)
play: add manpage, error reporting
Diffstat (limited to 'rc/bin/play')
-rwxr-xr-xrc/bin/play7
1 files changed, 4 insertions, 3 deletions
diff --git a/rc/bin/play b/rc/bin/play
index a5194b654..3fd688de8 100755
--- a/rc/bin/play
+++ b/rc/bin/play
@@ -31,15 +31,16 @@ fn play1 {
switch($1){
case *plain*
sed 's/ //g' | while(j=`{read}){
+ echo $"j >[1=2]
if(~ $"j http:* https:* HTTP:* HTTPS:*){
if(~ $#typ 0) typ=mp3
- echo $"j >[1=2]
hget -r 'Icy-MetaData: 0' $j | play1 $typ
}
if not {
- if(test -r $"j){
- echo $"j >[1=2]
+ if(test -r $"j)
play1 <$"j
+ if not {
+ echo $argv0: 'can''t open file:' $"j >[1=2]
}
}
}