emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* LaTeX minted --shell-escape error after updating to 8.0.3
@ 2013-05-26  1:53 Senthil Kumar M
  2013-05-26  6:44 ` Nick Dokos
  0 siblings, 1 reply; 7+ messages in thread
From: Senthil Kumar M @ 2013-05-26  1:53 UTC (permalink / raw)
  To: emacs-orgmode

Hi,

I updated org-mode to 8.0.3 (release_8.0.3-156-g847637). I got the
following error while using the LaTeX export, before the update all
was well and the PDF file was produced fine.

"Process completed with errors: [LaTeX error] [package error]

*Org PDF LaTeX Output* shows:

...
...

Package ifplatform Warning:
    shell escape is disabled, so I can only detect \ifwindows.

))

! Package minted Error: You must invoke LaTeX with the -shell-escape flag.

See the minted package documentation for explanation.
Type  H <return>  for immediate help.
 ...

l.21 \usemintedstyle
                    {autumn}

! Package minted Error: You must have `pygmentize' installed to use this packag
e.

See the minted package documentation for explanation.
Type  H <return>  for immediate help.
...
...


I have not changed any settings in my .emacs file (i.e.: (setq
org-export-latex-listings 'minted) is unchanged) and I never faced any
problems related to the `--shell-escape' before the update. pygmentize
is present in /usr/bin/ and it too worked perfectly before the update.

Any help is appreciated.

Thank you,

Sincerely,

Senthil

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: LaTeX minted --shell-escape error after updating to 8.0.3
  2013-05-26  1:53 LaTeX minted --shell-escape error after updating to 8.0.3 Senthil Kumar M
@ 2013-05-26  6:44 ` Nick Dokos
  2013-05-27 19:31   ` Senthil Kumar M
  0 siblings, 1 reply; 7+ messages in thread
From: Nick Dokos @ 2013-05-26  6:44 UTC (permalink / raw)
  To: emacs-orgmode

Senthil Kumar M <senthil.debian@gmail.com> writes:


> I updated org-mode to 8.0.3 (release_8.0.3-156-g847637). I got the
> following error while using the LaTeX export, before the update all
> was well and the PDF file was produced fine.
>
> "Process completed with errors: [LaTeX error] [package error]
>
> *Org PDF LaTeX Output* shows:
>
> ...
> ...
>
> Package ifplatform Warning:
>     shell escape is disabled, so I can only detect \ifwindows.
>
> ))
>
> ! Package minted Error: You must invoke LaTeX with the -shell-escape flag.
>
> See the minted package documentation for explanation.
> Type  H <return>  for immediate help.
>  ...
>
> l.21 \usemintedstyle
>                     {autumn}
>
> ! Package minted Error: You must have `pygmentize' installed to use this packag
> e.
>
> See the minted package documentation for explanation.
> Type  H <return>  for immediate help.
> ...
> ...
>
>
> I have not changed any settings in my .emacs file (i.e.: (setq
> org-export-latex-listings 'minted) is unchanged) and I never faced any
> problems related to the `--shell-escape' before the update. pygmentize
> is present in /usr/bin/ and it too worked perfectly before the update.
>

Well, you must have done something before to get around this problem.
My guess would be that you have customized the old
org-latex-to-pdf-process variable. The problem is that in 8.x, the
variable has been renamed to org-latex-pdf-process, so you need to do
to the new variable what you did to the old. E.g. the default setting
of this variable is three pdflatex calls:

,----
| ("pdflatex -interaction nonstopmode -output-directory %o %f"
|  "pdflatex -interaction nonstopmode -output-directory %o %f"
|  "pdflatex -interaction nonstopmode -output-directory %o %f")
`----

You'd need to add --shell-escape to each one.

-- 
Nick

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: LaTeX minted --shell-escape error after updating to 8.0.3
  2013-05-26  6:44 ` Nick Dokos
@ 2013-05-27 19:31   ` Senthil Kumar M
  2013-05-27 20:17     ` Nick Dokos
  0 siblings, 1 reply; 7+ messages in thread
From: Senthil Kumar M @ 2013-05-27 19:31 UTC (permalink / raw)
  To: emacs-orgmode

On Sat, May 25, 2013 at 11:44 PM, Nick Dokos <ndokos@gmail.com> wrote:
> Senthil Kumar M <senthil.debian@gmail.com> writes:
>
>
>> I updated org-mode to 8.0.3 (release_8.0.3-156-g847637). I got the
>> following error while using the LaTeX export, before the update all
>> was well and the PDF file was produced fine.
>>
>> "Process completed with errors: [LaTeX error] [package error]
>>
>> *Org PDF LaTeX Output* shows:
>>
>> ...
>> ...
>>
>> Package ifplatform Warning:
>>     shell escape is disabled, so I can only detect \ifwindows.
>>
>> ))
>>
>> ! Package minted Error: You must invoke LaTeX with the -shell-escape flag.
>>
>> See the minted package documentation for explanation.
>> Type  H <return>  for immediate help.
>>  ...
>>
>> l.21 \usemintedstyle
>>                     {autumn}
>>
>> ! Package minted Error: You must have `pygmentize' installed to use this packag
>> e.
>>
>> See the minted package documentation for explanation.
>> Type  H <return>  for immediate help.
>> ...
>> ...
>>
>>
>> I have not changed any settings in my .emacs file (i.e.: (setq
>> org-export-latex-listings 'minted) is unchanged) and I never faced any
>> problems related to the `--shell-escape' before the update. pygmentize
>> is present in /usr/bin/ and it too worked perfectly before the update.
>>
>
> Well, you must have done something before to get around this problem.
> My guess would be that you have customized the old
> org-latex-to-pdf-process variable. The problem is that in 8.x, the
> variable has been renamed to org-latex-pdf-process, so you need to do
> to the new variable what you did to the old. E.g. the default setting
> of this variable is three pdflatex calls:
>
> ,----
> | ("pdflatex -interaction nonstopmode -output-directory %o %f"
> |  "pdflatex -interaction nonstopmode -output-directory %o %f"
> |  "pdflatex -interaction nonstopmode -output-directory %o %f")
> `----
>
> You'd need to add --shell-escape to each one.
>
> --
> Nick
>
>

Hi,

Nick, thank you. Setting the org-latex-pdf-process variable as you
suggested resolved the LaTeX error during the export step.

However, the minted syntax colour highlighting does not work as
expected, all python/bash/XML code appear in one colour (black).

I had included (setq org-export-latex-listings 'minted) in my .emacs
file and it worked fine before the upgrade to 8.0.3.

Is there any variable that had changed and need to be set for the
syntax highlighting to work properly?

Thank you,

Sincerely,

Senthil


-/
For I am Vader, Darth Vader, Lord Vader. I can kill you with a single
thought." "Well, you'll still need a tray." "No, I will not need a
tray. I do not need a tray to kill you. I can kill you without a tray,
with the power of the Force, which is strong within me. Even though I
could kill you with a tray if I so wished, for I would hack at your
neck with the thin bit until the blood flowed across the canteen
floor." "No, the food is hot. You'll need a tray to put the food on."
"Oh, I see, the food is hot. I'm sorry, I did not realize.
--- Eddie Izzard

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: LaTeX minted --shell-escape error after updating to 8.0.3
  2013-05-27 19:31   ` Senthil Kumar M
@ 2013-05-27 20:17     ` Nick Dokos
  2013-05-27 20:40       ` Suvayu Ali
  2013-05-27 20:46       ` Senthil Kumar M
  0 siblings, 2 replies; 7+ messages in thread
From: Nick Dokos @ 2013-05-27 20:17 UTC (permalink / raw)
  To: emacs-orgmode

Senthil Kumar M <senthil.debian@gmail.com> writes:

> Nick, thank you. Setting the org-latex-pdf-process variable as you
> suggested resolved the LaTeX error during the export step.
>
> However, the minted syntax colour highlighting does not work as
> expected, all python/bash/XML code appear in one colour (black).
>

Just to make sure: you export to latex, open the resulting PDF file and
there is no syntax highlighting?

> I had included (setq org-export-latex-listings 'minted) in my .emacs
> file and it worked fine before the upgrade to 8.0.3.
>
> Is there any variable that had changed and need to be set for the
> syntax highlighting to work properly?
>

I don't think so. My guess is that your minted/pygments installation is
broken, i.e. nothing to do with org. What happens if you leave org out
of the equation altogether? I.e. take a simple tex file using minted and
pass it through ``pdflatex --shell-escap''?

-- 
Nick

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: LaTeX minted --shell-escape error after updating to 8.0.3
  2013-05-27 20:17     ` Nick Dokos
@ 2013-05-27 20:40       ` Suvayu Ali
  2013-05-27 20:46       ` Senthil Kumar M
  1 sibling, 0 replies; 7+ messages in thread
From: Suvayu Ali @ 2013-05-27 20:40 UTC (permalink / raw)
  To: emacs-orgmode

On Mon, May 27, 2013 at 04:17:07PM -0400, Nick Dokos wrote:
> Senthil Kumar M <senthil.debian@gmail.com> writes:
> 
> > I had included (setq org-export-latex-listings 'minted) in my .emacs
> > file and it worked fine before the upgrade to 8.0.3.
> >
> > Is there any variable that had changed and need to be set for the
> > syntax highlighting to work properly?

It should be org-latex-listings.  See the Org 8.0 upgrade guide.

  <http://orgmode.org/worg/org-8.0.html#sec-4>

Hope this helps,

-- 
Suvayu

Open source is the future. It sets us free.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: LaTeX minted --shell-escape error after updating to 8.0.3
  2013-05-27 20:17     ` Nick Dokos
  2013-05-27 20:40       ` Suvayu Ali
@ 2013-05-27 20:46       ` Senthil Kumar M
  2013-05-27 22:16         ` Nick Dokos
  1 sibling, 1 reply; 7+ messages in thread
From: Senthil Kumar M @ 2013-05-27 20:46 UTC (permalink / raw)
  To: emacs-orgmode

On Mon, May 27, 2013 at 1:17 PM, Nick Dokos <ndokos@gmail.com> wrote:
> Senthil Kumar M <senthil.debian@gmail.com> writes:
>
>> Nick, thank you. Setting the org-latex-pdf-process variable as you
>> suggested resolved the LaTeX error during the export step.
>>
>> However, the minted syntax colour highlighting does not work as
>> expected, all python/bash/XML code appear in one colour (black).
>>
>
> Just to make sure: you export to latex, open the resulting PDF file and
> there is no syntax highlighting?

Yes.


>
>> I had included (setq org-export-latex-listings 'minted) in my .emacs
>> file and it worked fine before the upgrade to 8.0.3.
>>
>> Is there any variable that had changed and need to be set for the
>> syntax highlighting to work properly?
>>
>
> I don't think so. My guess is that your minted/pygments installation is
> broken, i.e. nothing to do with org. What happens if you leave org out
> of the equation altogether? I.e. take a simple tex file using minted and
> pass it through ``pdflatex --shell-escap''?
>
> --
> Nick
>
>

If I run "pdflatex --shell-escape foo.tex" on the terminal, it gives
the same result (i.e. no colour highlighting).

While writing this reply, I saw the email from Suvayu Ali, about
changing org-export-latex-listings to org-latex-listings. That solved
this issue!

Thank you,

Sincerely,

Senthil

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: LaTeX minted --shell-escape error after updating to 8.0.3
  2013-05-27 20:46       ` Senthil Kumar M
@ 2013-05-27 22:16         ` Nick Dokos
  0 siblings, 0 replies; 7+ messages in thread
From: Nick Dokos @ 2013-05-27 22:16 UTC (permalink / raw)
  To: emacs-orgmode

Senthil Kumar M <senthil.debian@gmail.com> writes:

>>> Is there any variable that had changed and need to be set for the
>>> syntax highlighting to work properly?
>>>
>>
>> I don't think so. My guess is that your minted/pygments installation is
>> broken, i.e. nothing to do with org. What happens if you leave org out
>> of the equation altogether? I.e. take a simple tex file using minted and
>> pass it through ``pdflatex --shell-escap''?
>>
>
> If I run "pdflatex --shell-escape foo.tex" on the terminal, it gives
> the same result (i.e. no colour highlighting).
>

[Given Suvayu's answer, the following is irrelevant to this
 case. Nevertheless, these are basic things that one should do when
 something goes wrong, which is why I'm following up.]]

Was foo.tex what org produced or did you create it by hand? If the
former, did you look at foo.tex? Did it contain a minted environment?

> While writing this reply, I saw the email from Suvayu Ali, about
> changing org-export-latex-listings to org-latex-listings. That solved
> this issue!
>

Yup, I saw it too and kicked myself!

-- 
Nick

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2013-05-27 22:16 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-26  1:53 LaTeX minted --shell-escape error after updating to 8.0.3 Senthil Kumar M
2013-05-26  6:44 ` Nick Dokos
2013-05-27 19:31   ` Senthil Kumar M
2013-05-27 20:17     ` Nick Dokos
2013-05-27 20:40       ` Suvayu Ali
2013-05-27 20:46       ` Senthil Kumar M
2013-05-27 22:16         ` Nick Dokos

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).