[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Error when =(stata . t)= added to =org-babel-do-load-languages=
From: |
Nicolas Goaziou |
Subject: |
Re: [O] Error when =(stata . t)= added to =org-babel-do-load-languages= in an attempt to evaluate Stata code in org-mode |
Date: |
Sun, 15 Jan 2017 09:41:07 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) |
Hello,
Daniel Guinea <address@hidden> writes:
> However, I also want to evaluate Stata code in org-mode documents. For that
> I have
> downloaded the script =ob-stata.el= by Ista Zahn and I have saved it
> together with the other =ob-sth.el= files in
> =~/.emacs.d/elpa/org-20161224=. Moreover, I have edited the entry:
>
> (defcustom org-babel-stata-command inferior-STA-program-name
> "Name of command to use for executing stata code."
> :group 'org-babel
> :version "24.1"
> :package-version '(Org . "8.3")
> :type 'string)
>
> to reflect my current version of Org, so this piece of code currently
> stands as follows in my version of =ob-stata.el=:
>
> (defcustom org-babel-stata-command inferior-STA-program-name
> "Name of command to use for executing stata code."
> :group 'org-babel
> :version "24.1"
> :package-version '(Org . "9.0.3")
> :type 'string)
This part is not needed. :package-version is used to specify when
a defcustom was introduced or when its default value last changed.
> However, if I add =(stata . t)= to =org-babel-do-load-languages= as follows:
>
> (org-babel-do-load-languages
> 'org-babel-load-languages
> '((emacs-lisp . t)
> (sh . t)
> (R . t)
> (perl . t)
> (ruby . t)
> (python . t)
> (js . t)
> (haskell . t)
> (stata . t)
> (shell . t)))
>
> I get the following message when I restart emacs:
>
> ################# Beginning of debugger message ###################
>
> Debugger entered--Lisp error: (void-variable inferior-STA-program-name)
inferior-STAT-program-name is a variable defined in "ess-custom.el".
The error probably comes from the fact "ob-stata.el" is loaded before
"ess-custom.el" is.
You may want to tell the author of "ob-stata.el" about it. It is missing
a (require 'ess) somewhere in the library.
Regards,
--
Nicolas Goaziou