From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Mikhail Titov" Subject: Re: python/babel inline images Date: Tue, 5 Jun 2012 19:59:46 -0500 Message-ID: <007401cd437f$ab542b20$01fc8160$@us> References: <87pq9egifm.fsf@bye.fritz.box> <874nqp9580.fsf@gmx.com> Mime-Version: 1.0 Content-Type: text/plain; charset="koi8-r" Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([208.118.235.92]:36572) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Sc4eh-0001Sa-OF for emacs-orgmode@gnu.org; Tue, 05 Jun 2012 21:06:58 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Sc4bE-0006GF-Fk for emacs-orgmode@gnu.org; Tue, 05 Jun 2012 21:03:23 -0400 Received: from mailout-us.gmx.com ([74.208.5.67]:42268) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1Sc4bE-0006G7-89 for emacs-orgmode@gnu.org; Tue, 05 Jun 2012 20:59:48 -0400 In-Reply-To: <874nqp9580.fsf@gmx.com> Content-Language: en-us 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-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: 'Eric Schulte' , 'henry atting' Cc: emacs-orgmode@gnu.org > -----Original Message----- > From: emacs-orgmode-bounces+mlt=gmx.us@gnu.org [mailto:emacs-orgmode- > bounces+mlt=gmx.us@gnu.org] On Behalf Of Eric Schulte > Sent: Tuesday, June 05, 2012 9:57 AM > To: henry atting > Cc: emacs-orgmode@gnu.org > Subject: Re: [O] python/babel inline images > > I'm not python expert, but the code block should be run in your current > directory, e.g., the following outputs the current working path expected > for me. > > #+begin_src sh > pwd > #+end_src > > If you want to explicitly pass the current directory to your code block > as an argument, you could try something like the following > > #+begin_src python :var mydir=(file-name-directory (buffer-file-name)) > return mydir > #+end_src > I've noticed some inconsistency between various languages in this aspect. For instance, ob-R starts session in proper working directory, while all looks like everything (?) else does not. Should not it be somewhat standardized? I think it make sense to always cd to org doc folder. M.