emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* [PATCH] ob-coq cleanup
@ 2016-02-10  8:41 Alan Schmitt
  2016-02-10 12:13 ` Nicolas Goaziou
  0 siblings, 1 reply; 3+ messages in thread
From: Alan Schmitt @ 2016-02-10  8:41 UTC (permalink / raw)
  To: emacs-orgmode


[-- Attachment #1.1: Type: text/plain, Size: 51 bytes --]

Hello,

Here is a small patch cleaning up ob-coq.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: 0001-ox-coq.el-Clean-up.patch --]
[-- Type: text/x-patch, Size: 1477 bytes --]

From 4d3a37fbc078541bebb9bef73e6d81e85a95e048 Mon Sep 17 00:00:00 2001
From: Alan Schmitt <alan.schmitt@polytechnique.org>
Date: Wed, 10 Feb 2016 09:34:37 +0100
Subject: [PATCH] ox-coq.el: Clean up

* lisp/ob-coq.el: Create a variable `coq-program-name' and remove unused
  `org-babel-coq-eoe'.

  (org-babel-coq-initiate-session): use `coq-program-name'
---
 lisp/ob-coq.el | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/lisp/ob-coq.el b/lisp/ob-coq.el
index 4339a52..7aea5a6 100644
--- a/lisp/ob-coq.el
+++ b/lisp/ob-coq.el
@@ -35,11 +35,12 @@
 (declare-function run-coq "ext:coq-inferior.el" (cmd))
 (declare-function coq-proc "ext:coq-inferior.el" ())
 
+(defvar coq-program-name "coqtop"
+  "Name of the coq toplevel to run.")
+
 (defvar org-babel-coq-buffer "*coq*"
   "Buffer in which to evaluate coq code blocks.")
 
-(defvar org-babel-coq-eoe "org-babel-coq-eoe")
-
 (defun org-babel-coq-clean-prompt (string)
   (if (string-match "^[^[:space:]]+ < " string)
       (substring string 0 (match-beginning 0))
@@ -70,7 +71,7 @@ If there is not a current inferior-process-buffer in SESSION then
 create one.  Return the initialized session."
   (unless (fboundp 'run-coq)
     (error "`run-coq' not defined, load coq-inferior.el"))
-  (save-window-excursion (run-coq "coqtop"))
+  (save-window-excursion (run-coq coq-program-name))
   (sit-for 0.1)
   (get-buffer org-babel-coq-buffer))
 
-- 
2.7.0


[-- Attachment #1.3: Type: text/plain, Size: 121 bytes --]


Best,

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7
Monthly Athmospheric CO₂ (2016-01, Mauna Loa Obs.): 402.52

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 472 bytes --]

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ob-coq cleanup
  2016-02-10  8:41 [PATCH] ob-coq cleanup Alan Schmitt
@ 2016-02-10 12:13 ` Nicolas Goaziou
  2016-02-11  7:55   ` Alan Schmitt
  0 siblings, 1 reply; 3+ messages in thread
From: Nicolas Goaziou @ 2016-02-10 12:13 UTC (permalink / raw)
  To: Alan Schmitt; +Cc: emacs-orgmode

Hello,

Alan Schmitt <alan.schmitt@polytechnique.org> writes:

> Here is a small patch cleaning up ob-coq.

Thank you.

>   (org-babel-coq-initiate-session): use `coq-program-name'

Nitpick: missing capital and full stop.

Nothing else to say.

Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] ob-coq cleanup
  2016-02-10 12:13 ` Nicolas Goaziou
@ 2016-02-11  7:55   ` Alan Schmitt
  0 siblings, 0 replies; 3+ messages in thread
From: Alan Schmitt @ 2016-02-11  7:55 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 447 bytes --]

On 2016-02-10 13:13, Nicolas Goaziou <mail@nicolasgoaziou.fr> writes:

>> Here is a small patch cleaning up ob-coq.
>
> Thank you.
>
>>   (org-babel-coq-initiate-session): use `coq-program-name'
>
> Nitpick: missing capital and full stop.
>
> Nothing else to say.

Applied with this change in the commit message.

Best,

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7
Monthly Athmospheric CO₂ (2016-01, Mauna Loa Obs.): 402.52

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 472 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-02-11  7:55 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-10  8:41 [PATCH] ob-coq cleanup Alan Schmitt
2016-02-10 12:13 ` Nicolas Goaziou
2016-02-11  7:55   ` Alan Schmitt

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).