From mboxrd@z Thu Jan 1 00:00:00 1970 From: Joon Ro Subject: export fails with "byte-code: Before first headline at position ..." Date: Sun, 26 Apr 2015 14:35:53 -0500 Message-ID: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="_0a7d04a1-b74b-40be-b598-3e788bbaefda_" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60775) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmSLO-00086w-7J for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 15:35:58 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YmSLL-00069t-0q for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 15:35:58 -0400 Received: from col004-omc1s7.hotmail.com ([65.55.34.17]:51529) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmSLK-00069d-RO for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 15:35:54 -0400 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: "emacs-orgmode@gnu.org" --_0a7d04a1-b74b-40be-b598-3e788bbaefda_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi=2C When I try to export my org files I'm getting this error. For example: byte-code: Before first headline at position 1 in buffer Blog.org<2> I could not find any way to fix this - any help will be very appreciated. Thank you=2CJoon = --_0a7d04a1-b74b-40be-b598-3e788bbaefda_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hi=2C

<= div>When I try to export my org files I'm getting this error. For example:<= /div>

byte-code: Before first headline at position 1 in = buffer Blog.org<=3B2>=3B

I could not find any = way to fix this =3B- any help will be very appreciated.

<= /div>
Thank you=2C
Joon

= --_0a7d04a1-b74b-40be-b598-3e788bbaefda_-- From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rasmus Subject: Re: export fails with "byte-code: Before first headline at position ..." Date: Sun, 26 Apr 2015 23:00:18 +0200 Message-ID: <87sibmd2ql.fsf@gmx.us> References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:49522) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmTfR-0001AW-GH for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 17:00:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YmTfO-0002Co-AK for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 17:00:45 -0400 Received: from plane.gmane.org ([80.91.229.3]:44213) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmTfO-0002Cf-43 for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 17:00:42 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1YmTfH-00059d-OO for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 23:00:35 +0200 Received: from x5ce179dc.dyn.telefonica.de ([92.225.121.220]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 26 Apr 2015 23:00:30 +0200 Received: from rasmus by x5ce179dc.dyn.telefonica.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 26 Apr 2015 23:00:30 +0200 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: emacs-orgmode@gnu.org Hi Joon, Joon Ro writes: > When I try to export my org files I'm getting this error. For example: > byte-code: Before first headline at position 1 in buffer Blog.org<2> > I could not find any way to fix this - any help will be very appreciated. Could you please send us a minimal example and clear instructions on how to produce this error? I was unable to reproduce it. Thanks, Rasmus -- El Rey ha muerto. ¡Larga vida al Rey! From mboxrd@z Thu Jan 1 00:00:00 1970 From: Joon Ro Subject: Re: export fails with "byte-code: Before first headline at position ..." Date: Sun, 26 Apr 2015 16:13:00 -0500 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="_5db45454-d698-4659-893b-363b045ef993_" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:51368) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmTrN-0006t7-Gs for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 17:13:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YmTrK-0005aS-9b for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 17:13:05 -0400 Received: from col004-omc1s2.hotmail.com ([65.55.34.12]:60129) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YmTrK-0005aN-1D for emacs-orgmode@gnu.org; Sun, 26 Apr 2015 17:13:02 -0400 In-Reply-To: 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: "emacs-orgmode@gnu.org" --_5db45454-d698-4659-893b-363b045ef993_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Apparently it was caused by the following custom function for org-export-be= fore-parsing-hook that I had to remove the subtree with "beameronly" tag: (defun as/delete-ignored-heading (backend) (unless (equal backend 'beamer) =3B remove subtree with beameronly tag (org-map-entries (lambda () (progn (org-narrow-to-subtree) (org-cut-subtree) ) ) "+beameronly" 'tree) ) ) (setq org-export-before-parsing-hook '(as/delete-ignored-heading)) What I did wrong to cause this error? It worked for sum subtrees but not fo= r others. From: joon.ro@outlook.com To: emacs-orgmode@gnu.org Date: Sun=2C 26 Apr 2015 14:35:53 -0500 Subject: [O] export fails with "byte-code: Before first headline at positio= n ..." Hi=2C When I try to export my org files I'm getting this error. For example: byte-code: Before first headline at position 1 in buffer Blog.org<2> I could not find any way to fix this - any help will be very appreciated. Thank you=2CJoon = --_5db45454-d698-4659-893b-363b045ef993_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Apparently it was caused by=  =3Bthe following =3Bcustom function for org-export-before-parsing-= hook that I had to remove the subtree with "beameronly" tag:

=
(defun as/delete-ignored-heading (backend)
 = =3B =3B =3B (unless (equal backend 'beamer)

 =3B =3B =3B =3B =3B =3B remove subtree with beameron= ly tag
 =3B =3B =3B =3B =3B (org-map-entries
&nbs= p=3B =3B =3B =3B =3B =3B (lambda ()
 =3B =3B=  =3B =3B =3B =3B =3B =3B (progn
 =3B =3B=  =3B =3B =3B =3B =3B =3B =3B =3B (org-narro= w-to-subtree)
 =3B =3B =3B =3B =3B =3B =3B&n= bsp=3B =3B =3B (org-cut-subtree)
 =3B =3B =3B = =3B =3B =3B =3B =3B =3B =3B )
 =3B =3B&n= bsp=3B =3B =3B =3B =3B =3B )
 =3B =3B = =3B =3B =3B =3B "+beameronly" 'tree)
 =3B =3B = =3B =3B =3B )
)

(setq org-export-before= -parsing-hook '(as/delete-ignored-heading))

What I did wrong to cause =3Bthis error? It =3Bworked = for sum subtrees but not for others.



<= hr id=3D"stopSpelling">From:=3B joon.ro@outlook.com
To:=3B emacs-o= rgmode@gnu.org
Date:=3B Sun=2C 26 Apr 2015 14:=3B35:=3B53 -0500=
Subject:=3B [O] export fails with "=3Bbyte-code:=3B Before fi= rst headline at position ..."=3B

Hi=2C

When I try to export my = org files I'm getting this error. For example:=3B

byte-code:=3B Before first headline at position 1 in buffer Blog.org&= lt=3B2>=3B

I could not find any way to fix this&= #160=3B- any help will be very appreciated.

Thank = you=2C
Joon

=
= --_5db45454-d698-4659-893b-363b045ef993_--