mszep / pandoc_resume

The Markdown Resume
http://mszep.github.io/pandoc_resume/
MIT License
1.62k stars 756 forks source link

mactex > context not found (bin/sh mtxrun not found) #65

Closed molleweide closed 4 years ago

molleweide commented 4 years ago

First of all I am very grateful for this project; Thank you to everybody who has made this.

Expected Behavior

pdf file in output dir

Actual Behavior

no pdf. make command ends with: make: *** [pdf] Error 127

Steps to reproduce the behavior

clone to macOS > run make

➜ make
mkdir -p output
PANDOC_VERSION=`pandoc --version | head -1 | cut -d' ' -f2 | cut -d'.' -f1`; \
        if [ "$PANDOC_VERSION" -eq "2" ]; then \
                SMART=-smart; \
        else \
                SMART=--smart; \
        fi \

for f in markdown/*.md; do \
                FILE_NAME=`basename $f | sed 's/.md//g'`; \
                echo $FILE_NAME.html; \
                pandoc --standalone --include-in-header styles/chmduquesne.css \
                        --lua-filter=pdc-links-target-blank.lua \
                        --from markdown --to html \
                        --output output/$FILE_NAME.html $f \
                        --metadata pagetitle=$FILE_NAME;\
        done
resume.html
for f in markdown/*.md; do \
                FILE_NAME=`basename $f | sed 's/.md//g'`; \
                echo $FILE_NAME.pdf; \
                pandoc --standalone --template styles/chmduquesne.tex \
                        --from markdown --to context \
                        --variable papersize=A4 \
                        --output output/$FILE_NAME.tex $f > /dev/null; \
                mtxrun --path=output --result=$FILE_NAME.pdf --script context $FILE_NAME.tex > output/context_$FILE_NAME.log 2>&1; \
        done
resume.pdf
make: *** [pdf] Error 127

Versions

macOS Mojave

Pandoc and context versions pandoc 2.9.1 Compiled with pandoc-types 1.20, texmath 0.12, skylighting 0.8.3

I have installed mactex as well but it seems it is not being used.

OS information on non-Windows can use one of the following commands

cat /etc/*-release (i don't know what to do with this)
lsb_release -a
molleweide commented 4 years ago

My apologies if I am posting this in the wrong place; This is the first time I am asking about a github project. If I should ask this somewhere else please point me in the right direction.

nitrocode commented 4 years ago

What's your context version?

context --version

Have you tried using the docker container instead of running make?

docker-compose up -d
molleweide commented 4 years ago

Hi nitrocode and thanks for replying.

I can see that context is installed via mactex.

I have not tried using docker yet. I haven't gotten to learn what docker is yet.

I solved the problem now by adding /usr/local/texlive/2019/bin/x86_64-darwin to .profile

nitrocode commented 4 years ago

@molleweide Glad you got it to work.

Are you saying that the context binary was located in the /usr/local/texlive/2019/bin/x86_64-darwin directory so you had to append that directory to PATH in your .profile using something like this... ?

export PATH="$PATH:/usr/local/texlive/2019/bin/x86_64-darwin"

I wrote the above in case someone else runs into the same issue as you.

molleweide commented 4 years ago

Yes sir! That is correct. I added it to my .profile and then reloaded zsh. Now everything seems to work!