* [BUG] ox-texinfo can't export example blocks [9.6.9 (release_9.6.9 @ /usr/local/share/emacs/30.0.50/lisp/org/)] @ 2024-02-14 15:17 pva-outdoor 2024-02-18 15:38 ` Ihor Radchenko 0 siblings, 1 reply; 3+ messages in thread From: pva-outdoor @ 2024-02-14 15:17 UTC (permalink / raw) To: emacs-orgmode Remember to cover the basics, that is, what you expected to happen and what in fact did happen. You don't know how to make a good report? See https://orgmode.org/manual/Feedback.html#Feedback Your bug report will be posted to the Org mailing list. ------------------------------------------------------------------------ Hello, Team! It seems that in ox-texinfo.el the `string-match-p' is used instead of `string-equal' (here is my patch): --- /usr/local/share/emacs/30.0.50/lisp/org/ox-texinfo.el.gz +++ #<buffer ox-texinfo.el.gz> @@ -1680,7 +1680,7 @@ "Transcode a SRC-BLOCK element from Org to Texinfo. CONTENTS holds the contents of the item. INFO is a plist holding contextual information." - (let* ((lisp (string-match-p "lisp" + (let* ((lisp (string-equal "lisp" (org-element-property :language src-block))) (code (org-texinfo--sanitize-content (org-export-format-code-default src-block info))) Without this fix I can't export my `.org' files to `.texi' format as the :language property is nil for #+BEGIN_EXAMPLE ... #+END_EXAMPLE blocks. Emacs : GNU Emacs 30.0.50 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.18.0) of 2023-10-05 Package: Org mode version 9.6.9 (release_9.6.9 @ /usr/local/share/emacs/30.0.50/lisp/org/) -- С уважением, Андрей Петров. ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [BUG] ox-texinfo can't export example blocks [9.6.9 (release_9.6.9 @ /usr/local/share/emacs/30.0.50/lisp/org/)] 2024-02-14 15:17 [BUG] ox-texinfo can't export example blocks [9.6.9 (release_9.6.9 @ /usr/local/share/emacs/30.0.50/lisp/org/)] pva-outdoor @ 2024-02-18 15:38 ` Ihor Radchenko [not found] ` <877cj0swz1.fsf@yandex.ru> 0 siblings, 1 reply; 3+ messages in thread From: Ihor Radchenko @ 2024-02-18 15:38 UTC (permalink / raw) To: pva-outdoor; +Cc: emacs-orgmode pva-outdoor@yandex.ru writes: > It seems that in ox-texinfo.el the `string-match-p' is used instead of > `string-equal' (here is my patch): `string-match-p' is used there on purpose to mark lisp, emacs-lisp, and even elisp blocks with @lisp Texinfo markup. See https://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html#g_t_0040lisp > ... the > :language property is nil for #+BEGIN_EXAMPLE ... #+END_EXAMPLE blocks. `org-texinfo-src-block', which you modified in your patch, has nothing to do with example blocks. It only handles exporting src blocks (#+begin_src .. #+end_src). Example blocks are exported using @example Texinfo markup. See https://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html#g_t_0040example Example blocks have no notion of language in Texinfo. > Without this fix I can't export my `.org' files to `.texi' format ... Please describe your problem in more details. What do you mean by "can't export"? See https://orgmode.org/manual/Feedback.html#Feedback -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at <https://orgmode.org/>. Support Org development at <https://liberapay.com/org-mode>, or support my work at <https://liberapay.com/yantar92> ^ permalink raw reply [flat|nested] 3+ messages in thread
[parent not found: <877cj0swz1.fsf@yandex.ru>]
* Re: [BUG] ox-texinfo can't export example blocks [9.6.9 (release_9.6.9 @ /usr/local/share/emacs/30.0.50/lisp/org/)] [not found] ` <877cj0swz1.fsf@yandex.ru> @ 2024-02-24 10:05 ` Ihor Radchenko 0 siblings, 0 replies; 3+ messages in thread From: Ihor Radchenko @ 2024-02-24 10:05 UTC (permalink / raw) To: pva-outdoor [ Adding Org mailing list back to CC for public record ] pva-outdoor@yandex.ru writes: >> Please describe your problem in more details. What do you mean by "can't >> export"? See https://orgmode.org/manual/Feedback.html#Feedback > > To reproduce my problem you can write create an org-mode buffer (C-x b > 1.org M-x org-mode) with the following content: > > #+begin_src lua :tangle yes :noweb yes > aaa > <<second>> > #+end_src > > #+name: second > #+begin_src > bbb > #+end_src > > Then enable exporting to texinfo and export the buffer: > M-: (require 'ox-texinfo) > C-c C-e i t > > The folllowing backtrace appears (providing you already enabled > debugging on errors): Thanks! I fixed this and similar problems on main. https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=f90322377 Fixed. > Debugger entered--Lisp error: (wrong-type-argument stringp nil) > apply(debug error (wrong-type-argument stringp nil)) > edebug(error (wrong-type-argument stringp nil)) > signal(wrong-type-argument (stringp nil)) > edebug-signal(wrong-type-argument (stringp nil)) > string-match("lisp" nil nil t) > string-match-p("lisp" nil) > ... -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at <https://orgmode.org/>. Support Org development at <https://liberapay.com/org-mode>, or support my work at <https://liberapay.com/yantar92> ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-02-24 10:06 UTC | newest] Thread overview: 3+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2024-02-14 15:17 [BUG] ox-texinfo can't export example blocks [9.6.9 (release_9.6.9 @ /usr/local/share/emacs/30.0.50/lisp/org/)] pva-outdoor 2024-02-18 15:38 ` Ihor Radchenko [not found] ` <877cj0swz1.fsf@yandex.ru> 2024-02-24 10:05 ` Ihor Radchenko
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.