X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=development%2FMacOSX%2Flyxeditor;h=7431b3b99165ee529b34e609b74f56d7f4b1d661;hb=dc06714adb8ba0678b1d92e017360526eb36a1b2;hp=aeb6370dfd7732010b5a73148da2fe9f2f1a1a09;hpb=81d70b41a121e9f096fdf06b93859eac8584dabe;p=lyx.git diff --git a/development/MacOSX/lyxeditor b/development/MacOSX/lyxeditor index aeb6370dfd..7431b3b991 100755 --- a/development/MacOSX/lyxeditor +++ b/development/MacOSX/lyxeditor @@ -64,7 +64,8 @@ done # echo "preferences file sets lyxpipe as ${LYXPIPE}" test -z "${LYXPIPE}" && { - ABS_SYSTEM_LYXDIR='/Applications/LyX.app/Contents/Resources' + ABS_SYSTEM_LYXDIR=$(dirname "$0") + ABS_SYSTEM_LYXDIR=$(dirname "${ABS_SYSTEM_LYXDIR}")"/Resources" test -d "${ABS_SYSTEM_LYXDIR}" || { echo "Failed to find ABS_SYSTEM_LYXDIR: ${ABS_SYSTEM_LYXDIR}" >&2 exit 1 @@ -86,9 +87,9 @@ if [ -n "$LYXPIPE" -a -p "$LYXPIPE".in ]; then MAC_LYXPIPE_CONTENTS="LYXCMD:macdvix:server-goto-file-row:$file $2" # echo "$MAC_LYXPIPE_CONTENTS" echo "$MAC_LYXPIPE_CONTENTS" > "${LYXPIPE}".in || { echo "Cannot write to lyxpipe." ; exit 2 ; } - while read line < "${LYXPIPE}".out ; do + while read line ; do echo LyX said: $line - done || { echo "Cannot read from lyxpipe." ; exit 2 ; } + done < "${LYXPIPE}".out || { echo "Cannot read from lyxpipe." ; exit 2 ; } else echo "Our best guess sets lyxpipe as ${LYXPIPE}" echo "But the lyxpipe could not be found."