修复 mammoth 路径

hotfix/paypal-note
LMR 3 years ago
parent 72cc2089dd
commit f100eaa776

@ -462,7 +462,7 @@ class Info_amp extends CI_Controller
$yarnbin = 'C:\Users\cht77\AppData\Local\Yarn\bin\mammoth '; $yarnbin = 'C:\Users\cht77\AppData\Local\Yarn\bin\mammoth ';
$test_host = '//202.103.68.62:9096'; $test_host = '//202.103.68.62:9096';
} else { } else {
$yarnbin = 'C:\Users\lmr\AppData\Local\Yarn\bin\mammoth '; $yarnbin = APPPATH . 'mammoth/mammoth ';
$test_host = ''; $test_host = '';
} }
$command = $yarnbin . $docx_path . ' --output-dir=' . $img_dir . ' 2>&1'; $command = $yarnbin . $docx_path . ' --output-dir=' . $img_dir . ' 2>&1';

@ -0,0 +1,15 @@
#!/bin/sh
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
case `uname` in
*CYGWIN*) basedir=`cygpath -w "$basedir"`;;
esac
if [ -x "$basedir//bin/sh" ]; then
"$basedir//bin/sh" "$basedir/../Data/global/node_modules/.bin/mammoth" "$@"
ret=$?
else
/bin/sh "$basedir/../Data/global/node_modules/.bin/mammoth" "$@"
ret=$?
fi
exit $ret

@ -0,0 +1 @@
@"%~dp0\..\Data\global\node_modules\.bin\mammoth.cmd" %*
Loading…
Cancel
Save