On Wed, Dec 14, 2011 at 6:04 PM, Allan Odgaard mailinglist@textmate.org wrote:
If the command has no shebang, it should work like 1.x (i.e. auto-source bash_init.sh).
Interesting. From what I can tell, my copy in "Pristine" (the copy 1.5 uses, correct?) also has a shebang, but it was able to find bash_init.sh/pre...
Where can I see the full source for your bundle command?
It's the ⌘R (Engrave & View) for the Lilypond.tmbundle in "Managed Bundles". This is the unmodified source:
#!/bin/bash # # beforeRunningCommand: saveActiveFile # input: none # keyEquivalent: @r # name: Engrave and View # output: showAsHTML # scope: source.lilypond # uuid: E8B6A543-90A6-46A4-A307-B21B67EF7F2F #
. "${TM_SUPPORT_PATH}/lib/webpreview.sh" html_header 'Engrave & View' "$TM_FILENAME" echo '<h2>Engraving…</h2>'
: ${TM_LILYPOND:="$(find_app Lilypond.app)/Contents/Resources/bin/lilypond"} [[ ! -f "$TM_LILYPOND" ]] && TM_LILYPOND=lilypond
if ! type >/dev/null -p "$TM_LILYPOND"; then echo "Error locating <a href='http://lilypond.org/web/'>lilypond</a> on your system." exit fi
cd "$TM_DIRECTORY" "$TM_LILYPOND" "$TM_FILENAME" | pre
if [[ -f "${TM_FILEPATH%.*}.pdf" ]]; then echo "Opening PDF…"; open "${TM_FILEPATH%.*}.pdf" else echo "Error generating PDF file." fi