emacs-orgmode
[
Top
][
All Lists
]
Advanced
[
Date Prev
][
Date Next
][
Thread Prev
][
Thread Next
][
Date Index
][
Thread Index
]
Re: [O] Python src blocks indent
From
:
Fabrice Popineau
Subject
:
Re: [O] Python src blocks indent
Date
:
Wed, 17 May 2017 14:45:53 +0200
Hi,
I mean that in the Org buffer I have for example :
#+BEGIN_SRC ipython :session
def fact(n):
if n == 1:
return 1
else:
return n * fact(n-1)
#+END_SRC
That is, there is a 2 spaces indentation of the whole code block, and the code block is properly indented.
When I export it, I get :
def fact(n):
if n == 1:
return 1
else:
return n * fact(n-1)
in the IPython cell (basically, the notebook format is JSON and it is easy to count those spaces in the code string in the JSON file)
and the 2 org-edit-src-content-indentation have been removed
only on the first line. The other ones have 6 or 10 spaces instead of 4 and 8.
Given that changing
org-edit-src-content-
indentation to 0 fixes this problem, I wonder if there
is something wrong in the logic where this variable is used (only one place in org-src).
But that could well be that it is not taken into account in places where it should.
Regards,
Fabrice
reply via email to
[
Prev in Thread
]
Current Thread
[
Next in Thread
]
[O] Python src blocks indent
,
Fabrice Popineau
,
2017/05/16
Re: [O] Python src blocks indent
,
Nicolas Goaziou
,
2017/05/17
Re: [O] Python src blocks indent
,
Fabrice Popineau
<=
Re: [O] Python src blocks indent
,
Nicolas Goaziou
,
2017/05/17
Re: [O] Python src blocks indent
,
Fabrice Popineau
,
2017/05/17
Prev by Date:
Re: [O] [PATCH v2] org-sort: Read compare-func in interactive calls
Next by Date:
Re: [O] [PATCH 2/2] org-refile: Fix inconsistency when listing refile targets
Previous by thread:
Re: [O] Python src blocks indent
Next by thread:
Re: [O] Python src blocks indent
Index(es):
Date
Thread