我试着在我的系统上运行pdflatex的flymake。以下代码包含在我的.emacs文件中:
(require 'flymake)
(defun flymake-get-tex-args (file-name)
(list "pdflatex"
(list "-file-line-error" "-draftmode" "-interaction=nonstopmode" file-name)))
(add-hook 'LaTeX-mode-hook 'flymake-mode)错误:
Flymake: Configuration error has occurred while running(pdflatex -file-line-error -draftmode -interaction=nonstopmode /home/.../myfile_flymake.tex).Flymake will be switched OFF我一直在寻找解决方案,但找不到。希望有人能帮我。
提前感谢
发布于 2013-08-02 23:35:33
我猜是因为换行。调用包装器脚本而不是pdflatex,至少为我解决了这个问题:
#!/bin/bash
export max_print_line=1000
export error_line=254
export half_error_line=238
pdflatex "$@"发布于 2013-09-13 08:03:30
从flymake manual
以下错误会导致一条警告消息,并关闭缓冲区的flymake模式。
CFGERR :语法检查进程返回非零退出代码,但未报告错误/警告。这表明可能存在配置错误(例如,没有适用于语法检查工具的错误消息模式)
所以我的猜测是,pdflatex会被调用,解析您的.tex文件,然后给出一个非零的退出代码,而不是“报告”任何错误或警告。
要测试这一点,请在shell中运行以下命令:
pdflatex -file-line-error -draftmode -interaction=nonstopmode /home/.../myfile.tex现在,输入:
echo $?查看退出代码。如果它是非零的,并且没有错误或警告的迹象,那么这将解释您所看到的行为。
我只是在这里问了一个针对这种情况的问题:Using emacs for .tex files with Flymake - error with unbalanced braces
https://stackoverflow.com/questions/16596835
复制相似问题