On 12/18/2012 10:40 AM, Edgar Aichinger wrote:
Am Montag, 17. Dezember 2012, 22:28:53 schrieb rosea.grammostola:
On 12/17/2012 08:18 PM, Brent Busby wrote:
On Mon, 17 Dec 2012, rosea.grammostola wrote:
How do I set midnight commander to let mplayer play my audio files?
Well, just for some ideas, here's some stuff from my ~/.mc/bindings :
### Sound files ###
regex/\.([wW][aA][vV]|[vV][oO][cC]|[aA][uU]|[sS][mM][pP]|[aA][iI][fF][fF])$
Open=sndfile-play %f>/dev/null 2>&1&
View=%view{ascii} soxi %f
regex/\.([sS][nN][dD])$
Open=sndfile-play %f>/dev/null 2>&1&
View=%view{ascii} sndfile-info %f
regex/\.([mM][oO][dD]|[sS]3[mM]|[xX][mM]|[iI][tT]|[mM][tT][mM]|669|[sS][tT][mM]|[uU][lL][tT]|[fF][aA][rR])$
Open=mikmod %f
#Open=tracker %f
regex/\.([mM][pP]3)$
Open=mpg123 %f
View=%view{ascii} mpg123 -vtn1 %f 2>&1 | sed -n
'/^Title/,/^Comment/p;/^MPEG/,/^Audio/p'
regex/\.([oO][gG][gG|aA|vV|xX])$
Open=ogg123 -d alsa -o use_mmap:yes %f
View=%view{ascii} ogginfo %s
regex/\.([sS][pP][xX]|[fF][lL][aA][cC])$
Open=play %f
View=%view{ascii} soxi %f
This does not work here
# WAV
regex/\.(wav|WAV)$
Include=sound
# FLAC
regex/\.(flac|FLAC|fla|FLA)$
Include=sound
# MP3
regex/\.(mp3|MP3)$
Include=sound
# AAC
regex/\.(m4a|M4A)$
Include=sound
# Microsoft ASF
regex/\.(wma|WMA)$
Include=sound
include/sound
Open=(mplayer %f>/dev/null 2>&1&)
#(mplayer %f>/dev/null 2>&1&)
#Open=mplayer -vo null %f
This is the sound stanza from openSUSE's mc.ext file (etc/mc/mc.ext, gets copied to ~/.config/mc/mc.ext once you do F9/edit extensions file), and it works well here:
### Sound files ###
regex/\.([wW][aA][vV]|[sS][nN][dD]|[vV][oO][cC]|[aA][uU]|[sS][mM][pP]|[aA][iI][fF][fF]|[sS][nN][dD])$
Include=audio
# Open=if [ "$DISPLAY" = "" ]; then play %f; else (xmms %f>/dev/null 2>&1&); fi
regex/\.([mM][oO][dD]|[sS]3[mM]|[xX][mM]|[iI][tT]|[mM][tT][mM]|669|[sS][tT][mM]|[uU][lL][tT]|[fF][aA][rR])$
Open=mikmod %f
#Open=tracker %f
regex/\.([wW][aA][wW]22)$
Open=vplay -s 22 %f
regex/\.([mM][pP]3)$
Include=audio
# Open=if [ "$DISPLAY" = "" ]; then mpg123 %f; else if [ -z "`which realplay`" ]; then (xmms -e %f 1>/dev/null 2>&1&); else (realplay %f>/dev/null 2>&1&); fi; fi
# View=%view{ascii} mpg123 -vtn1 %f 2>&1 | sed -n '/^Title/,/^Comment/p;/^MPEG/,/^Audio/p'
regex/\.([mM][kK][aA])$
Include=audio
regex/\.([oO][gG][gG|aA|vV|xX])$
Include=audio
# Open=ogg123 %f
# Open=if [ "$DISPLAY" = "" ]; then ogg123 %f; else (xmms -e %f>/dev/null 2>&1&); fi
View=%view{ascii} ogginfo %s
regex/\.([sS][pP][xX]|[fF][lL][aA][cC])$
Include=audio
# Open=if [ "$DISPLAY" = "" ]; then play %f; else (xmms %f>/dev/null 2>&1&); fi
regex/\.([mM][iI][dD][iI]?|[rR][mM][iI][dD]?)$
Open=timidity %f
regex/\.([wW][mM][aA])$
Open=mplayer -vo null %f
View=%view{ascii} mplayer -quiet -slave -frames 0 -vo null -ao null -identify %f 2>/dev/null | tail +13 || file %f
include/audio
Open=mplayer %f
View=%view{ascii} mplayer -identify -vo null -ao null -frames 0 %f 2>&1 | sed -n '/^ID_/p'
### Play lists ###
regex/\.([mM]3[uU]|[pP][lL][sS])$
Open=mplayer -vo null -playlist %f
# Open=if [ -z "$DISPLAY" ]; then mplayer -vo null -playlist %f; else (xmms -p %f>/dev/null 2>&1&); fi
Thanks, that works!
_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@xxxxxxxxxxxxxxxxxxxx
http://lists.linuxaudio.org/listinfo/linux-audio-user