From: Adam Porter <adam@alphapapa.net>
To: emacs-orgmode@gnu.org
Subject: Re: BUG: Wrong indentation inside src block
Date: Fri, 15 Apr 2016 19:57:10 -0500 [thread overview]
Message-ID: <87bn5axteh.fsf@alphapapa.net> (raw)
In-Reply-To: loom.20160416T004508-200@post.gmane.org
fm4d <m@fm4d.net> writes:
> Hello, I found an indentation bug in the master branch.
>
> Steps to reproduce:
>
> * Test 1
> ** Test 2
> #+BEGIN_SRC emacs-lisp
> (setq foo 1
> bar 2)
> #+END_SRC
>
> Paste this code into org-mode buffer with org-startup-indented turn on
> org-indented-mode. You should see the src block missindented like this:
>
> (setq foo 1
> bar 2)
>
> I've tracked this bug to this commit
> http://repo.or.cz/org-mode.git/commit/a311a856514e9245074b02c89d51a9f339784d1c
Hm, I'm not sure I understand the problem. Org doesn't automatically
reindent source blocks, as far as I know. You can <C-c '> and reindent
the source buffer, and then when you save it it will be reflected in the
Org buffer. I made a little function to do that as a command, which I
could share if you like.
Also, the examples you gave have mixed spaces and tabs, so it's hard to
tell whether they're indented correctly. For example, I see the second
example indented correctly, while the first is not. You might try
turning on whitespace-mode, which makes it easy to see where they are.
BTW, that commit is a large merge commit, so it's hard to see where the
problem would be. You could try bisecting it on the branch it was
merged from.
next prev parent reply other threads:[~2016-04-16 0:57 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-15 22:56 BUG: Wrong indentation inside src block fm4d
2016-04-16 0:57 ` Adam Porter [this message]
2016-04-16 8:45 ` fm4d
2016-04-16 10:14 ` Nicolas Goaziou
2016-04-16 14:31 ` Adam Porter
2016-04-16 14:50 ` John Hendy
2016-04-16 15:42 ` fm4d
[not found] ` <5f4b206cd53f4894b6e8fe2bb5334a25@HE1PR01MB1898.eurprd01.prod.exchangelabs.com>
2016-04-16 16:24 ` Eric S Fraga
2016-04-16 17:12 ` fm4d
2016-04-19 19:18 ` Nicolas Goaziou
2016-04-20 17:16 ` fm4d
2016-04-20 21:42 ` Nicolas Goaziou
2016-04-20 21:52 ` fm4d
2016-04-20 22:02 ` Nicolas Goaziou
2016-04-16 17:29 ` fm4d
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87bn5axteh.fsf@alphapapa.net \
--to=adam@alphapapa.net \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.