-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve error messages about pandoc --to pdf
#1155
Comments
If you want PDF output, you do not need any But I agree, the error message that pops up if you use |
@KurtPfeifle: Thanks for the extra info. Can you propose short and helpful error messages for the two example invocations above? |
|
Given @KurtPfeifle's error message, I would try next:
|
|
@Toxaris - thanks for the suggestion. |
I guess this got lost somewhere, because right now the error message is pretty confusing: |
@mariusoutier What are you doing to get that message, and what version of pandoc are you using? |
|
OK, I see. This makes sense if you understand what's going on internally -- pandoc generates latex, html, or ms and converts that to a pdf -- but I agree it's confusing. |
Pandoc can produce pdfs, but there is no pdf writer. Instead, in order to produce pdfs, you have to use the latex writer with an output file name that ends in
.pdf
. I understand the technical reasons for this behavior. Unfortunately, the user interface is not perfect if people accidently use a--to pdf
flag:The first error message suggests that pandoc cannot produce pdfs, and the second error message suggests that there is a pdf writer, but it is broken. Both error messages fail to help users achieve their goal, presumably to create a pdf with pandoc.
I see two options for how to improve the behavior:
These error messages could explain how to produce a pdf. Approximately:
These invocations could try to produce a pdf, essentially "faking" a pdf writer. The first invocation would have to fail because there's no output file name:
The second invocation would have the same as
pandoc --to latex -o hello.pdf
.The text was updated successfully, but these errors were encountered: