| | Resources | Configuration | CM Pocket Ref | |
|
|
Most of the required programs are installed automatically using Gentoo's
emerge command. I manually install Common Music, FOMUS, and Limp
under the /usr/local/ subdirectory. I also do some special
tweaking of Limp so that it works more seamlessly with Common Music.
Get the latest versions of Common Music and FOMUS from their SVN repositories.
PREFIX=/usr/local
mkdir $PREFIX/cm
svn co http://commonmusic.svn.sf.net/svnroot/commonmusic/trunk/cm $PREFIX/cm
mkdir $PREFIX/fomus
svn co svn://common-lisp.net/project/fomus/svn/fomus/trunk $PREFIX/fomus
Uncomment (or add) (use-system :fomus) at the end of the
cm/src/cm.lisp source file. Then make a symbolic link for
cm with the following command:
cd /usr/local/bin
ln -s /usr/local/cm/bin/cm.sh cm
While logged in as user root, run the cm command.
You need to be root only the first time you run CM so that it can
generate the additional files it needs to run. Now you can login with your
regular userid and run CM.
Because I work on a terminal with a white background, I also changed the
following line in Limp's vim/mode.vim file.
hi BracketsBlock ctermbg=235 guibg=lightgray
hi BracketsBlock ctermbg=lightgray guibg=lightgray
I don't care for the auto-folding default in Limp, so I also remove this line.
setlocal foldmethod=marker foldmarker=(,) foldminlines=1
And finally, I changed these two lines in Limp's vim/mode.vim
file to use my favorite xterm and so that the terminal stays open when I'm
working from gVim. This makes for an especially nice working environment within
the excellent tiling window manager dwm.
let cmd = "xterm -e " . cmd
let cmd = "urxvt -e " . cmd
let b:listener_keep_open=0
let b:listener_keep_open=1
There are two ways in which to start up the Common Music environment. The
first is simply to run the command cm and it will automatically
detect your Lisp installation, run it, and load CM within it. The other,
more useful, method is to load it up manually after Lisp is launched by Limp
from within your Vim session. Then you have your full interactive environment
with your editor, Lisp, and CM. In order to facilitate this method, put the
following function definition in your SBCL initialization file,
~/.sbclrc, and then you can easily load Common Music by calling
the function (cm-load) at the toplevel.
(defun cm-load ()
(load "/usr/local/cm/src/cm.lisp" :verbose nil)
(funcall 'cm))
Play MIDI file with the following command:
timidity opus.midi
Create FLAC file with the following command:
timidity -OF -o opus.flac opus.midi