Version 0.3
by Richard Brauer
This is pretty easy: Just hit return.
Muff reads a set of file extensions from the config files and provides some sort of frontend for dealing with files of that extension.
If searches a directory tree for all files with given extensions and lets you search a list of these songs for expressions. If any names of files in the list match this expression, you can choose any of these files to be added to a playlist.
This playlist can either be a file read by muff-play (see extra section in this help file) or xmms' playlist, depending on a choice you made in muff's config file.
You can also control some vital functions of the chosen playback program via this program, including play, forward and rewind.
This program does not play mp3, ogg or avi-files.
Muff does not search for any files but files with the extensions you specified in the configuration file.
Muff does not remove single songs (e.g. the highlighted one or the one being played at the moment from xmms' playlist because this does not seem to be doable from the shell. When using muff-play however, you can edit it's playlist using a standard text editor.
If your searchpattern matches more than 997 files, only the first 997 matching files will be displayed.
Muff can act as a frontend to two programs: muff-play and xmms.
xmms is the well known X-Multimedia-System, a clone of the windoze program named winamp. Muff expects you to have xmms-shell installed (this is a small program that allows for calling many of xmms' funtions from the shell that are not easilly accessible otherways).
muff-play is a little daemon program written in bash. It is in "halted" state most of the time and is only woken up by special events. It does not play back any files itself, but calls appropriate pieces of software for that purpose. In the standard configuration, muff-play can play .ogg, .mp3, .avi and .ogm files, if you have the right programs installed (ogg123, mpg321 and mplayer are default).
The mode of playback (muff-play or xmms) is specified in the configuration file.
Now the program will display a list of all the files whose filenames match the expression you entered. You may browse this list using the up and down arrow keys. Get back to the main menu by pressing either return or escape.
Don't press space, or if you do, only press it ntimes per highlited item, where n is an even number.
Do the same as described in section 2.2 but make n an odd number for those items you want to add to the xmms playlist and do not try to exit pressing escape or selecting the nooooh button in which cases your choices will not have any consequences. Still these options may come in handy if you decide not to select the selected files ;-)
By default the database file (where Muff stores the names of all the mp3files so it does not have to search your harddisk all the time) is stored somewhere in your /tmp directory. Therefore this file will be deleted after rebooting on most systems. If the database file does not exist on startup, it will be created automatically. Still you might have reasons to update the file while running the program, e.g. if you added or deleted mp3 files. Do this by selecting "Scan" from the main menu [hmmm, why the hell do I try to explain all those f***ing obvious things?].
There's another thing about updating the database which is probably not that obvious. I rather think it is IMPORTANT!!!
In the muff configuration file (/etc/muff.conf) you can define a path in which muff shall look for mp3 files. On startup, muff checks whether this path is a valid one and if it is not, muff will set this path variable to a path underneath which all mp3 files on your harddisk can be found. On most systems, this will be the root directory ( "/" ).
No scanning your whole harddisk for mp3 files with find can take a few minutes, if you have huge and/or slow harddisks. Therefore muff will only use "locate" to update its database. If you now change something about your database, you'll need to run "updatedb" to for these changes to be recognized by muff.
It is therefore very important that you have a sensible value for mp3path predefined in /etc/muff.conf! Muff will remind you of this with a nasty message box.
You can choose the following items from the main menu:
Choose the appropriate items from the main menu.
This submenu offers more options for xmms control
When using Muff on your own computer, you'll probably want it to scan for mp3 files in the directory you store your mp3 files in. For this purpose the $mp3path-variable has to be set to a directory that contains all the mp3 files you want to be scanned by muff.
The best way of doing this is to edit the /etc/muff.conf file and set the value of mp3dir to a nice path on your system. The configuration file is well documented, so you don't need to be afraid that you make anything really really stupid ;-)
If the mp3path defined in /etc/muff.conf does not make sense, muff will try to guess a good path for your system, which will very probably result in this path being " / " which is really, really bad.
As muff uses "egrep" to scan the database for patterns, you can use any regular expression grep understands for searching for files. A few important examples include:
| fly | would search for any file containing the pattern "fly" |
| fly.mp3 | You may believe, that this finds any files containing
the pattern "fly.mp3" but then you are mistaken. In
regular expressions, the dot ( . ) represents exactly
one arbitrary character. If you want to search for a
dot, you have to escape it using a backslash
. ) |
fly
.mp3 |
Only filenames containing "fly.mp3" match this expression |
| fl[aeiouy] | finds all filenames containing either of "fla" "fle" "fli" "flo" "flu" "fly". So you might find filesnames containing "mark knopfler" or "pink floyd", and also "fluid" "flaw" "flown" "fly" "flight" etc but not "berflssig" (which is the german word for superfluous or unneccessary with all the horrible umlauts simply omitted). |
| fl[^ aeiouy] | finds anything that contains a pattern of three letters the first of which are "fl" and the third NOT one of "a" "e" "i" "o" "u" or "y". Hence this would find "berflssig" but not all the things fl[aeiouy] would find. |
rem[^ /] +mp3 |
Finds all filenames that contain a pattern that begins with "rem", ends with "mp3" and has inbetween an arbitrary number (at least one of characters other than a slash (/). So if all your files from REM are in a subdirectory .../rem/, none of them will be found, unless some have a filename like ".../rem/rem_-_losing_my_religion.mp3". In other words: all files will be found that have the pattern "rem ... mp3" as part of their filename without path. Hence you'll find anything like "song (remix).mp3" or "...remains.mp3" or ".../rem/rem_-_daysleeper.mp3" but not ".../rem/walk_unafraid.mp3" |
| (ga)* | Finds all files whose name contain a sequence of 0 or more matches of "ga". Because we are using egrep, you don't need to escape the brackets. As the expression on the left would find all files (the star means at least zero times, not at least once), it is useless. Therefore you may say: |
(ga) + |
To find filenames containing a sequence of at least one match of "ga". If you want to easily find a filename containing "ga ga" this is probably quite stupid, as it will show your whole Peter Gabriel collection as well. Hence you may try |
(ga ) + |
or of course just |
| ga ga | but that looks so unimpressive ;-) |
(drive
.mp3^ ) |
Finds all filenames that end on "drive.mp3". Useful if you don't want to find files like "... you drive me crazy.mp3". |
See the re_syntax manpage ("man re_syntax") for more details. And have a look at the egrep documentation (man egrep) to find out about the most complicated patterns to search for.
Edit the muff shellscript (muff, not muff-run) and just make sure the first command (Eterm ...) does not work by, e.g. switching Eterm to eterm. Muff will notice that this doesn't work and start an xterm instead, assuming that everyone has xterm installed.
I'm using Eterm because on my system the predefined background colour for dialog is more beautiful (a lot darker) in Eterms than in xterms. Now don't ask me why, I don't know and I really don't care that much.
When starting, muff looks in /etc/muff.conf for predefined values of the following variables:
| mp3dir | the directory underneath which muff searches for mp3 files. Adjust this variable according to you system. Please really do this! |
| tmpdir | the directory in which muff stores its temporary files. I'd recommend not changing this one. If muff notices that it cannot write in $tempdir, it will set this variable to /tmp/muff.$USER, i.e. if your login name is "bill", temporary files will be stored in /tmp/muff.bill |
| helpdir | the directory in which muff looks for its help file. On most systems /usr/share/doc should do fine. |
| paranoia | governs whether muff checks if xmms is running all the time or not. If paranoia is set to 0 (zero), then muff will only check if xmms is running on startup. If paranoia is set to 1, muff will check every time it does something that affects xmms. Actually I think that this option is not that important. |
| intelligent_grep | This setting is for people who like to be totally in control of what is going on on their computer. By default, muff replaces any space in your search-expression by "[ _-]". This means, that if you enter something like "meat loaf", all files will be found whose name contains either of "meat loaf" "meat_loaf" and "meat-loaf". I think that this makes a lot of sence, because of the many different ways in which people name their mp3 files. Anyway, you may not want muff to do this. If you don't, set the intelligent_grep variable to 0 (zero). Leave it on 1 if you like this setting. |
It is really important (at the moment, i.e. release 0.1) that you keep the exact layout of the items in /etc/muff.conf . This is: case matters, the Lines that contain parameter settings must not begin with anything else but the parameter name and there has to be exactly one space before and after the "=". Hence, if
>denotes the beginning of a line, settings must look like
>parameter = setting
Any one of several species of Old World warblers, esp. the common European species (Sylvia cinerea), called also strawsmear, nettlebird, muff, and whitecap, the garden whitethroat, or golden warbler (S. hortensis), and the lesser whitethroat (S. curruca).
To handle awkwardly; to fumble; to fail to hold, as a ball, in catching it.
acronym for Music File Finder, some shell-scripts for bash.
Basically, I'd advise to read it if you want to know more about muff than you do already know. If you know pretty much of everything there is to know about it, you'll be disappointed.
If you are reading this help file from within muff, you can scroll up and down using the arrow keys.
By pressing "/" (slash) you can enter an expression to search the help file for. Please not that this search IS case sensitive.
By pressing "n" you can search for the next occurence of the expression.
If some lines are too long you can scroll to the left or to the right using the left or right arrow keys respectively.
muff is published under the gpl. A copy of gpl should be found in /usr/share/doc/muff/ If not, have a look at http://www.gnu.org/copyleft/gpl.html
First, download the muff tarball from some appropriate server.
Secondly, copy the tarball to some directory I'll simply call i-dir.
Third, cd to i-dir and type "tar xzvf muff.tar.gz"
Fourth, cd to i-dir/muff and run ./install
You don't need to be root to run i-dir/muff/install, but you'll be asked for your root passwort if you aren't.
If you want to change the default locations for the muff files (see 3.9), you may change some settings in the i-dir/muff/schmeisse shell script. If you change the $helpdir settings there, you'll have to change this variable in muff-run as well.
These are the default locations. You may change them during installation (see 3.8)
Executables are /usr/local/bin/muff /usr/local/bin/muff-run
The helpfiles are in /usr/share/doc/muff
If muff ever uses a configuration file, it will be /etc/muff.conf
There is not much of support for muff, but if you have any questions you may try to mail me at richard.brauer@physik.rwth-aachen.de or take a look at the muff homepage http://muff.sourceforge.net
Apart from that -- as muff is no more than a bash script making use of dialog, egrep, xmms and xmms-shell, you may want to consult these programs' online documentation (man foo).
muff-play is a program written in bash and running in daemon mode that can be used to open files from a playlist files with external programs that are specified in a configuration file. It is intended to be used in combination with muff (obviously) but that's not necessary.
muff is a pretty nice program if you have lots of files on your computer that you want to open, but you don't always know where they are (or can't stand typing these f*ing long pathnames). When using xmms for playback, muff can only be used for opening files that don't confuse xmms. If you use muff-play, you can open all sorts of files, as long as your system provides programs to open these files with. You can actually still use xmms, by specifying xmms as mp3command (and oggcommand) and giving the appropriate options (typically -n 0 - -enqueue).
And even if you're only using muff for it's most obvious purpose, i.e. searching for and playing back music files, muff-play has some interesting features. The most important one is that you can edit muff-play's playlist in a text editor during playback, giving you far better playlist handling than xmms does.
muffplayer = muff-play
These parameters have to be given in this precise order. There is no warning, if the parameters don't make sense, and I don't know what happens if they are wrong/stupid/whatever.
Typically you will call muff-play saying something like
muff-play /tmp/muff/muffcom.file /home/yourname/.muff.conf \
/tmp/muff /tmp/muff/muff_play.lock
Note: in bash-syntax the backslash means that the command will be continued on the next line.
That's because it is a daemon mode program. After being started, muff-play reads some configuration values from the configuration file (extensions you want it to know plus appropriate programs with the right options for your system...).
It then goes into halt state (It calls something like "kill -s 19 $$")
Each time muff-play is woken up (see below) it looks for the communication file (typically /tmp/muff/muffcom.file) and if it exists, it reads a command from that file. Commands are just numbers. As of version 0.3, muff-play knows what to do for the following commands:
After doing what you want it to do, muff-play goes into halt-state again.
Now there are two ways to wake up muff-play.
Now this won't do anything special, because you forgot to specify a command. So what you have to do before going to step b) is saying
echo 1 > /tmp/muff/muffcom.file
(instead of 1 you can put any of the commands muff-play understands.)
To nicely cause muff-play to stop running, wake it up and make it execute the command "0". This way it will terminate the last child process it called (note that muff-play uses "kill -9" to do this).
muff-play writes a lot of status output into a logfile. This is situated in the temp dir and called "muffplaysownlogfile.log", so by default it is /tmp/muff/muffplaysownlogfile.log
If you want to test muff-play, it is a good idea to "tail -f" this file.
This document was generated using the LaTeX2HTML translator Version 2K.1beta (1.48)
Copyright © 1993, 1994, 1995, 1996,
Nikos Drakos,
Computer Based Learning Unit, University of Leeds.
Copyright © 1997, 1998, 1999,
Ross Moore,
Mathematics Department, Macquarie University, Sydney.
The command line arguments were:
latex2html -split 0 -ascii_mode -no_math help.tex
The translation was initiated by Richard Brauer on 2003-05-06