Re: [BUG] Emacs-29.0.60: (setopt org-babel-load-languages ...) may cause warnings

2023-03-03 Thread Ihor Radchenko
Bastien Guerry  writes:

> Ihor Radchenko  writes:
>
>>> 1. I have assigned my copyright for Emacs stuff to the FSF
>>
>> Bastien, may you please confirm?
>
> I do, sorry for the delay.

Updated the contributor list.
https://git.sr.ht/~bzg/worg/commit/a5eaeb0d

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Re: [BUG] Emacs-29.0.60: (setopt org-babel-load-languages ...) may cause warnings

2023-03-03 Thread Ihor Radchenko
gerard.vermeu...@posteo.net writes:

> I have attached an amended patch with the :version tag removed.

Thanks!
Applied onto bugfix.
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=e8010e8a9

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Re: [BUG] Emacs-29.0.60: (setopt org-babel-load-languages ...) may cause warnings

2023-02-28 Thread Bastien Guerry
Ihor Radchenko  writes:

>> 1. I have assigned my copyright for Emacs stuff to the FSF
>
> Bastien, may you please confirm?

I do, sorry for the delay.

-- 
 Bastien Guerry



Re: [BUG] Emacs-29.0.60: (setopt org-babel-load-languages ...) may cause warnings

2023-02-02 Thread gerard . vermeulen



On 02.02.2023 09:26, Ihor Radchenko wrote:

gerard.vermeu...@posteo.net writes:


May you please convert the diff into a patch with changelog entry and
commit message? See
https://orgmode.org/worg/org-contribute.html#org045e318


patch attached.


Thanks!


1. I have assigned my copyright for Emacs stuff to the FSF


Bastien, may you please confirm?

2. My initial version of the patch was against bugfix and now I have 
set

:package-version to "9.6"


Correct.
You can also remove :version tag while we are at it. It is redundant
when :package-version is provided (we are slowly getting rid of the
:version tags across Org).

 according to the instructions on the org-contribute page. I do 
not

know if this is acceptable (it
 feels a bit like breaking the rules), but I am happy to redo the
patch for main.


bugfix is fine. This is a trivial patch.


I have attached an amended patch with the :version tag removed.


0001-org.el-Sync-org-babel-load-languages-with-Babel-file.patch
Description: Binary data


Re: [BUG] Emacs-29.0.60: (setopt org-babel-load-languages ...) may cause warnings

2023-02-02 Thread Ihor Radchenko
gerard.vermeu...@posteo.net writes:

>> May you please convert the diff into a patch with changelog entry and
>> commit message? See 
>> https://orgmode.org/worg/org-contribute.html#org045e318
>
> patch attached.

Thanks!

> 1. I have assigned my copyright for Emacs stuff to the FSF

Bastien, may you please confirm?

> 2. My initial version of the patch was against bugfix and now I have set 
> :package-version to "9.6"

Correct.
You can also remove :version tag while we are at it. It is redundant
when :package-version is provided (we are slowly getting rid of the
:version tags across Org).

>  according to the instructions on the org-contribute page. I do not 
> know if this is acceptable (it
>  feels a bit like breaking the rules), but I am happy to redo the 
> patch for main.

bugfix is fine. This is a trivial patch.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



Re: [BUG] Emacs-29.0.60: (setopt org-babel-load-languages ...) may cause warnings

2023-02-01 Thread gerard . vermeulen

Hi Igor,

On 31.01.2023 11:34, Ihor Radchenko wrote:

gerard.vermeu...@posteo.net writes:


The attached patch synchronizes the =defcustom= with the rest of the
code base, groups languages by org-babel file, and uses camel-case to
spell languages (the new fashion).


Thanks!
May you please convert the diff into a patch with changelog entry and
commit message? See 
https://orgmode.org/worg/org-contribute.html#org045e318


patch attached.

Two points:
1. I have assigned my copyright for Emacs stuff to the FSF
2. My initial version of the patch was against bugfix and now I have set 
:package-version to "9.6"
according to the instructions on the org-contribute page. I do not 
know if this is acceptable (it
feels a bit like breaking the rules), but I am happy to redo the 
patch for main.


Best regards -- Gerard

0001-org.el-Sync-org-babel-load-languages-with-Babel-file.patch
Description: Binary data


Re: [BUG] Emacs-29.0.60: (setopt org-babel-load-languages ...) may cause warnings

2023-01-31 Thread Ihor Radchenko
gerard.vermeu...@posteo.net writes:

> The attached patch synchronizes the =defcustom= with the rest of the
> code base, groups languages by org-babel file, and uses camel-case to
> spell languages (the new fashion).

Thanks!
May you please convert the diff into a patch with changelog entry and
commit message? See https://orgmode.org/worg/org-contribute.html#org045e318

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at .
Support Org development at ,
or support my work at 



[BUG] Emacs-29.0.60: (setopt org-babel-load-languages ...) may cause warnings

2023-01-30 Thread gerard . vermeulen

Hi,

I have been replacing to calls to =custom-set-variables= with calls to 
the safer

=setopt= (new in Emacs-29.0.60) and I discovered that calling
src_emacs-lisp{(setopt org-babel-load-languages '((eshell t) (emacs-lisp 
t)))}
raises a warning because =eshell= is missing from the 
=org-babel-load-languages=
=defcustom=.  The code below shows that this =defcustom= is quit out of 
sync with

the rest of the code base:

#+header: :wrap "src emacs-lisp :results silent :tangle no"
#+begin_src emacs-lisp :exports both :results value pp :exports both
(defun all-org-babel-execute-fns ()
  "Find `ob-LANGUAGE' files in Org defining 
`org-babel-execute:LANGUAGE'.


Return a list of items where the filename is the `car' of each item and 
the

`cdr' of each item lists the `org-babel-execute:LANGUAGE' functions."
  (let* ((dir (file-name-parent-directory (locate-library "org")))
 (names (directory-files dir t (rx "ob-" (+ print)  ".el" 
eos

(cl-loop for name in names
 for found = (has-org-babel-execute-fn name)
 when found collect found)))

(defun has-org-babel-execute-fn (name)
  (let* ((buffer (find-file-noselect name))
 (base (file-name-base (buffer-file-name buffer)))
 (regexp (rx "defun" (+ blank) "org-babel-execute:" (group (+ 
graphic

 (matches))
(save-match-data
  (save-excursion
(with-current-buffer buffer
  (save-restriction
(widen)
(goto-char 1)
(while (re-search-forward regexp nil t 1)
  (push (match-string-no-properties 1) matches))
(when matches
  `(,base ,@matches

(all-org-babel-execute-fns)
#+end_src

#+RESULTS:
#+begin_src emacs-lisp :results silent :tangle no
(("ob-C" "C" "D" "C++" "cpp")
 ("ob-R" "R")
 ("ob-awk" "awk")
 ("ob-calc" "calc")
 ("ob-clojure" "clojurescript" "clojure")
 ("ob-css" "css")
 ("ob-ditaa" "ditaa")
 ("ob-dot" "dot")
 ("ob-emacs-lisp" "emacs-lisp")
 ("ob-eshell" "eshell")
 ("ob-forth" "forth")
 ("ob-fortran" "fortran")
 ("ob-gnuplot" "gnuplot")
 ("ob-groovy" "groovy")
 ("ob-haskell" "haskell")
 ("ob-java" "java")
 ("ob-js" "js")
 ("ob-julia" "julia")
 ("ob-latex" "latex")
 ("ob-lilypond" "lilypond")
 ("ob-lisp" "lisp")
 ("ob-lua" "lua")
 ("ob-makefile" "makefile")
 ("ob-maxima" "maxima")
 ("ob-ocaml" "ocaml")
 ("ob-octave" "octave" "matlab")
 ("ob-org" "org")
 ("ob-perl" "perl")
 ("ob-plantuml" "plantuml")
 ("ob-processing" "processing")
 ("ob-python" "python")
 ("ob-ruby" "ruby")
 ("ob-sass" "sass")
 ("ob-scheme" "scheme")
 ("ob-screen" "screen")
 ("ob-sed" "sed")
 ("ob-shell" "shell")
 ("ob-sql" "sql")
 ("ob-sqlite" "sqlite"))
#+end_src

The attached patch synchronizes the =defcustom= with the rest of the
code base, groups languages by org-babel file, and uses camel-case to
spell languages (the new fashion).

Best regards -- Gerard


fix-org-babel-load-languages.patch
Description: Binary data