>>> "Berry," == Berry, Charles <ccbe...@ucsd.edu> writes:

    >> On Aug 3, 2017, at 1:04 AM, Uwe Brauer <o...@mat.ucm.es> wrote:
    >> 
    >> 
    >> 
    >> I just checked and situation is absurd. Here is the minimal example:
    >> [snip]
    >> 
    >> When I set org-export-babel-evaluate nil, then the code is *not*
    >> evaluated, *but* the code block *and* the result are exported.
    >> 
    > [snip]
    >> When I set org-export-babel-evaluate to t, export but say no to the
    >> question whether or not to evaluate, *only* the result is exported,
    >> which is what I want.
    >> 
    >> Is this a *bug*? I wait a day, then I will file a bug report.

    > No. It is *obsolete* and its replacement is not recommended for your 
application. 

Thanks I did not finish reading the documentation, my bad

So I tried
#+begin_src matlab  :results output latex :exports results  :eval never-export 
X=[1];
disp('\begin{displaymath}')
fprintf('X&=%g\\\\ \n', X)
disp('\end{displaymath}')
#+end_src

which then worked as expected. Before I played around with
code I found in
https://emacs.stackexchange.com/questions/17744/is-there-a-way-to-make-org-mode-ignore-src-blocks-when-exporting-to-html

But your suggestion is cleaner. Thanks

Uwe 


Reply via email to