[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
windows, elisp function to call batch file, shell-command, Whitaker's wo
From: |
Hugh Lawson |
Subject: |
windows, elisp function to call batch file, shell-command, Whitaker's words |
Date: |
Fri, 2 Dec 2016 05:49:17 -0800 (PST) |
User-agent: |
G2/1.0 |
The problem is that William Whitaker's Words program returns an error when I
try to call it with this setup, in Windows 10. I have a Latin text in a
buffer. I put the cursor on a Latin word, and strike F12. The elisp function
calls the latin.bat bath file, which calls the words latin dictionary program.
I think something is wrong either with my elisp function or my batch file.
The following error is displayed:
=>Raised END_ERROR, although in STANDARD_INPUT
^Z is inappropriate keyboard input, WORDS should be terminated with a blank line
Giving up!
In .emacs file:
(defun whitaker-lookup ()
"Lookup Latin word at point in Whitaker's words"
(interactive )
(shell-command (concat "C:\latin " (thing-at-point 'word))))
;;C:\latin is a batch file
(global-set-key (kbd "<f12>") 'whitaker-lookup)
Here is the batch file, latin.bat
cd c:\WORDS
words
The same error occurs if I issue these commands:
m-x shell-command
latin
However, if I go into the shell mode buffer I can make things work:
mx-shell
c:\> cd c:\words
c:\words> words
;;calls the words program with no error
c:\words> latin
;; calls the batch file which calls the words program, successfully.
- windows, elisp function to call batch file, shell-command, Whitaker's words,
Hugh Lawson <=
- Re: windows, elisp function to call batch file, shell-command, Whitaker's words, tomas, 2016/12/02
- Re: windows, elisp function to call batch file, shell-command, Whitaker's words--solved, Hugh Lawson, 2016/12/02