From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Andreas Kiermeier" Subject: Problem with including file Date: Thu, 2 May 2019 14:33:25 +0930 Message-ID: <02c901d500a4$61ee4760$25cad620$@gmail.com> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_02CA_01D500F4.02B9AA00" Return-path: Received: from eggs.gnu.org ([209.51.188.92]:47859) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hM3tX-0000Q9-94 for emacs-orgmode@gnu.org; Thu, 02 May 2019 01:04:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hM3tI-00032T-93 for emacs-orgmode@gnu.org; Thu, 02 May 2019 01:04:19 -0400 Received: from mail-pf1-x435.google.com ([2607:f8b0:4864:20::435]:42492) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hM3tE-0001z3-4e for emacs-orgmode@gnu.org; Thu, 02 May 2019 01:04:12 -0400 Received: by mail-pf1-x435.google.com with SMTP id 13so221906pfw.9 for ; Wed, 01 May 2019 22:03:32 -0700 (PDT) Received: from AcerS13AK ([58.170.78.176]) by smtp.gmail.com with ESMTPSA id t5sm52130173pfh.141.2019.05.01.22.03.29 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 01 May 2019 22:03:30 -0700 (PDT) Content-Language: en-au List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: emacs-orgmode@gnu.org This is a multipart message in MIME format. ------=_NextPart_000_02CA_01D500F4.02B9AA00 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Hi, I've just run into a problem with exporting a file to latex. In a nutshell, my org files usually contain various analyses and output in R. I generally don't include the source in the file, but instead tangle all source blocks at the end and include the source code file in an Appendix. This has worked in the past, but now the included file is not actually include. An example (close to minimal) consist of the two files below - test.org and test.R (both in the same folder). When exporting test.org to PDF, the source block is correctly exported, while the included file does not appear to be included at all (see also test.tex below). Any thoughts would be greatly appreciated. Thanks, Andreas --- begin test.org ---- #+STARTUP: content indent hidestars fninline #+PROPERTY: header-args:R :session *R* :cache no #+PROPERTY: header-args+ :results output #+PROPERTY: header-args+ :exports results #+PROPERTY: header-args+ :eval never-export #+PROPERTY: header-args+ :tangle yes #+OPTIONS: toc:nil H:5 #+LATEX_HEADER: \usepackage{minted} * Intro #+begin_src R :results none :exports code ls() #+end_src * Data Analysis Source Code #+INCLUDE: "test.R" src R --- end test.org ---- --- begin test.R ---- ls() --- end test.R ---- --- begin test.tex ---- % Created 2019-05-02 Thu 14:08 % Intended LaTeX compiler: pdflatex \documentclass[11pt]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{graphicx} \usepackage{grffile} \usepackage{longtable} \usepackage{wrapfig} \usepackage{rotating} \usepackage[normalem]{ulem} \usepackage{amsmath} \usepackage{textcomp} \usepackage{amssymb} \usepackage{capt-of} \usepackage{hyperref} \usepackage{here} \usepackage{color} \usepackage{fancyhdr} \usepackage{fancybox} \usepackage{xspace} \usepackage{minted} \author{Andreas Kiermeier} \date{\today} \title{} \hypersetup{ pdfauthor={Andreas Kiermeier}, pdftitle={}, pdfkeywords={}, pdfsubject={}, pdfcreator={Emacs 25.3.1 (Org mode 9.2.3)}, pdflang={English}} \begin{document} \section{Intro} \label{sec:org6eb9726} \begin{minted}[]{r} ls() \end{minted} \section{Data Analysis Source Code} \label{sec:org98a88b4} \end{document} --- begin test.text ---- ------=_NextPart_000_02CA_01D500F4.02B9AA00 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

Hi,

I’ve just = run into a problem with exporting a file to latex.

In a nutshell, my org files usually contain various = analyses and output in R.

I generally = don’t include the source in the file, but instead tangle all = source blocks at the end and include the source code file in an = Appendix. This has worked in the past, but now the included file is not = actually include.

An example (close = to minimal) consist of the two files below - test.org and test.R (both = in the same folder).

When exporting = test.org to PDF, the source block is correctly exported, while the = included file does not appear to be included at all (see also test.tex = below).

Any thoughts would be greatly = appreciated.

Thanks,

Andreas

 

--- begin = test.org ----

#+STARTUP: content = indent hidestars fninline

#+PROPERTY: = header-args:R :session *R* :cache no

#+PROPERTY: header-args+ :results = output

#+PROPERTY: header-args+ = :exports results

#+PROPERTY: = header-args+ :eval never-export

#+PROPERTY: header-args+ :tangle yes

#+OPTIONS: toc:nil H:5

#+LATEX_HEADER: \usepackage{minted}

 

* = Intro

 

#+begin_src R :results none :exports = code

ls()

#+end_src

 

* Data = Analysis Source = Code           &nb= sp;           &nbs= p;            = ;  

 

#+INCLUDE: = "test.R" src R

--- end = test.org ----

 

--- begin test.R ----

ls()

--- end test.R = ----

 

--- begin test.tex ----

% Created 2019-05-02 Thu 14:08

% Intended LaTeX compiler: pdflatex

\documentclass[11pt]{article}

\usepackage[utf8]{inputenc}

\usepackage[T1]{fontenc}

\usepackage{graphicx}

\usepackage{grffile}

\usepackage{longtable}

\usepackage{wrapfig}

\usepackage{rotating}

\usepackage[normalem]{ulem}

\usepackage{amsmath}

\usepackage{textcomp}

\usepackage{amssymb}

\usepackage{capt-of}

\usepackage{hyperref}

\usepackage{here}

\usepackage{color}

\usepackage{fancyhdr}

\usepackage{fancybox}

\usepackage{xspace}

\usepackage{minted}

\author{Andreas Kiermeier}

\date{\today}

\title{}

\hypersetup{

= pdfauthor=3D{Andreas Kiermeier},

= pdftitle=3D{},

= pdfkeywords=3D{},

= pdfsubject=3D{},

pdfcreator=3D{Emacs = 25.3.1 (Org mode 9.2.3)},

 pdflang=3D{English}}

\begin{document}

 

 

\section{Intro}

\label{sec:org6eb9726}

 

\begin{minted}[]{r}

ls()

\end{minted}

 

\section{Data Analysis Source Code}

\label{sec:org98a88b4}

\end{document}

--- = begin test.text ----

------=_NextPart_000_02CA_01D500F4.02B9AA00--