#!/bin/bash #*************************************# # Script to run lilypond on specified # # file and open in Acrobat Reader # #*************************************# # gets complete filename of file srcfile="`eval echo $1`" # gets the filename without .ly FILENOEXTENSION="`echo $srcfile | sed -e 's/\..*$//'`" # close current Acrobat Reader window wmctrl -c "Adobe Reader" # runs lilypond on specified file # lilypond $srcfile acroread $FILENOEXTENSION.pdf & sleep 2 rm $FILENOEXTENSION.ps