Commit 5f403d05 authored by ALO's avatar ALO

Fix issue #2

Fix evince file path on mdtest script
parent 7644ea35
......@@ -7,16 +7,17 @@ MARKDOWN_PROJECT_PATH=$(dirname $0)
USAGE="usage: $0 mdFilePath"
[[ -z ${1} ]] && echo ${USAGE} >&2 && exit 1
MD_FILE=${1}
MD_FILE_PATH=${1}
MD_FILE_NAME=$(basename ${MD_FILE_PATH})
OUT_DIR=$(mktemp -d)
OUT_FILENAME=${MD_FILE/%.md/.pdf}
OUT_FILE_NAME=${MD_FILE_NAME/%.md/.pdf}
${MARKDOWN_PROJECT_PATH}/md2pdf.sh ${MD_FILE} ${OUT_DIR}
evince ${OUT_DIR}/${OUT_FILENAME}
${MARKDOWN_PROJECT_PATH}/md2pdf.sh ${MD_FILE_PATH} ${OUT_DIR}
evince ${OUT_DIR}/${OUT_FILE_NAME}
# Clean temp files
rm ${OUT_DIR}/${OUT_FILENAME}
rm ${OUT_DIR}/${OUT_FILE_NAME}
rmdir ${OUT_DIR}
exit 0
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment