lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Leopard?


From: Andrea Valle
Subject: Re: Leopard?
Date: Thu, 14 Feb 2008 10:59:41 +0100

Thanks Hans I will take it into account once on Leopard


Best

-a-



On 13 Feb 2008, at 11:09, Hans Aberg wrote:

On 13 Feb 2008, at 05:31, Benedict Singer wrote:

Yes. If you have Lilypond in /Applications then you can run /Applications/Lilypond.app/Contents/Resources/bin/lilypond music.ly and then open the result in Preview. Preview in Leopard will also pick up file changes without having to close and reopen the file, so you can just leave it open.

Here is a crash course (not OS X 10.5 specific) on how to run LilyPond from the Terminal:

* Might get the System Preferences <http://www.rubicode.com/Software/RCDefaultApp/>.
Then set .ly files to open with your favorite editor (also Xcode is fine) -perhs possible by the Finder "Get Info" window. This makes it possible to open .ly files from Terminal using
  open foo.ly
One can also open files using -a
  open -a 'QuickTime Player' foo.midi
The -t option opens to the preferred editor:
  open -t foo.bar
Type
  man open
for more information (quit with q - see 'man less').

* One might create a file named .profile for search paths (for X11, which does not create a login shell, it should be in .bashrc). For example, if you do not already have one, it might be made by (don't include the Fink, MacPorts, and MacTeX parts if you do not use them, don't include the lines ----, and finish the 'cat' part using <control-D>):
--------
cd
cat > .profile
# Add to end of searchpath:
append_path()
{
  if ! eval test -z "\"\${$1##*:$2:*}\"" -o -z "\"\${$1%%*:$2}\"" -o -z "\"\${$1##$2:*}\"" -o -z "\"\${$1##$2}\"" ; then
    eval "$1=\$$1:$2"
  fi
}

# Add to beginning of searchpath:
prepend_path()
{
  if ! eval test -z "\"\${$1##*:$2:*}\"" -o -z "\"\${$1%%*:$2}\"" -o -z "\"\${$1##$2:*}\"" -o -z "\"\${$1##$2}\"" ; then
    eval "$1=$2:\$$1"
  fi
}

# Set system searchpaths:

# In the case a directory may exist (depending on the program) both with and without
# parent directory 'share/' (like in the cae of MANPATH and INFOPATH), the 'share/'
# version is put first, as it is what is used in /usr on Mac OS X FreeSD UNIX.
# The idea is that if a program is somehow adapted to this platform, the the stuff will
# be moved to the 'share/' variation, and should thus be ovverride the unadapted versions.

PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11R6/bin
MANPATH=/usr/share/man:/usr/X11R6/man
INFOPATH=/usr/share/info
LIBPATH=/usr/lib:/usr/X11R6/lib

# Prepend Fink searchpaths:
test -r /sw/bin/init.sh && . /sw/bin/init.sh

# Prepend MacPorts (former DarwinPorts) searchpaths:
prepend_path PATH /opt/local/bin:/opt/local/sbin
prepend_path MANPATH /opt/local/share/man:/opt/local/man
prepend_path INFOPATH /opt/local/share/info:/opt/local/info
prepend_path LIBPATH /opt/local/lib

# Prepend MacTeX paths
prepend_path PATH /usr/texbin
prepend_path MANPATH /usr/local/texlive/2007/texmf/doc/man
prepend_path INFOPATH /usr/local/texlive/2007/texmf/doc/info

# Prepend /usr/local/ searchpaths:
prepend_path PATH /usr/local/bin:/usr/local/X11R6/bin
prepend_path MANPATH /usr/local/share/man:/usr/local/man
prepend_path INFOPATH /usr/local/share/info:/usr/local/info
prepend_path LIBPATH /usr/local/lib
------------------------------------------------
Then create a new Terminal window, to make sure this file is read.

* Create a script for running lilypond by
cd
mkdir -p local/bin
cd local/bin
cat > lilypond
exec /Applications/LilyPond.app/Contents/Resources/bin/lilypond "$@"

(Finish by the 'cat' part with <control>-D, then do)
chmod u+x lilypond

After this, you may run lilypond on a file named say foo.ly from any directory by typing
  lilypond foo.ly
Open the PDF by
  open foo.pdf

* Use the <tab> key frequently, to get the file completions. To get the file path, one can also drop the file from Finder onto Terminal.

  Hans Åberg



--------------------------------------------------
Andrea Valle
--------------------------------------------------
CIRMA - DAMS
Università degli Studi di Torino
--------------------------------------------------


"
Think of it as seasoning
. noise [salt] is boring
. F(blah) [food without salt] can be boring
. F(noise, blah) can be really tasty
"
(Ken Perlin on noise)






reply via email to

[Prev in Thread] Current Thread [Next in Thread]