From mboxrd@z Thu Jan 1 00:00:00 1970 From: Brian Carlson Subject: Re: PATCH: ox: Starting source code export at non-zero (-n value) Date: Wed, 25 May 2016 23:06:47 -0400 Message-ID: <57466847.3010507@abutilize.com> References: <573A9100.3020503@abutilize.com> <87k2iobglr.fsf@saiph.selenimh> <57428051.4000103@abutilize.com> <87zirf9r5w.fsf@saiph.selenimh> <87bn3v9oxp.fsf@saiph.selenimh> Reply-To: hacker@abutilize.com Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37793) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5ldg-0002x0-H0 for emacs-orgmode@gnu.org; Wed, 25 May 2016 23:07:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b5ldb-0003zs-AT for emacs-orgmode@gnu.org; Wed, 25 May 2016 23:07:11 -0400 Received: from gateway33.websitewelcome.com ([192.185.146.87]:53929) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5ldb-0003uH-3x for emacs-orgmode@gnu.org; Wed, 25 May 2016 23:07:07 -0400 Received: from cm1.websitewelcome.com (cm.websitewelcome.com [192.185.0.102]) by gateway33.websitewelcome.com (Postfix) with ESMTP id 72241B408B7D0 for ; Wed, 25 May 2016 22:06:52 -0500 (CDT) Received: from pool-173-76-187-225.bstnma.fios.verizon.net ([173.76.187.225]:57810 helo=[192.168.1.11]) by gator3208.hostgator.com with esmtpsa (TLSv1.2:DHE-RSA-AES128-SHA:128) (Exim 4.86_1) (envelope-from ) id 1b5ldJ-000Xbi-3q for emacs-orgmode@gnu.org; Wed, 25 May 2016 22:06:49 -0500 In-Reply-To: <87bn3v9oxp.fsf@saiph.selenimh> 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 On 2016-05-24 16:33, Nicolas Goaziou wrote: > Completing myself Great. Thanks! Very much appreciated. I went back and forth on the tests with the "string formatting." I should have gone with my original thoughts ;) The fixes to (org-export-get-loc) were a bit beyond my skill level. I don't work in lisp/scheme/emacs-lisp too much. Usually I know just enough to be dangerous ;) So Thanks! >> Applied, with a small refactoring. Thank you. No problem. Hope it helps others. >> Please let us know when the FSF paperwork is done I put the signed paperwork into the mail this evening. > Also, could you provide and ORG-NEWS entry for that patch? Sure. I'll use previous entries as a starting point. I was thinking that the entry should go under: Version 9.0/New Features/Export/ unless there's a more appropriate place in the Document. Here's what I thought about putting. I can make a patch if that is preferred means of submission. If what I've written doesn't make sense let me know. --8<---------------cut here---------------start------------->8--- **** Line Numbering in SRC/EXAMPLE blocks support arbitrary start number The -n option to SRC and EXAMPLE blocks can now take an numeric argument to specify the staring line number for the source or example block. The +n option can now take a numeric argument that will be added to the last line number from the previous block as the starting point for the SRC/EXAMPLE block. #+BEGIN_SRC emacs-lisp -n 20 ;; this will export with line number 20 (message "This is line 21") #+END_SRC #+BEGIN_SRC emacs-lisp +n 10 ;; This will be listed as line 31 (message "This is line 32") #+END_SRC --8<---------------cut here---------------end--------------->8--- I realize that the org texinfo manual probably needs to be updated, as well. I'll take a stab at updating that unless someone else wants to take that on. Thanks, ;-b