emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Starting ispell in some fixed directory


From: Slawomir Nowaczyk
Subject: Re: Starting ispell in some fixed directory
Date: Thu, 05 Oct 2006 23:36:05 +0200

Hello,

Any comments on this?

On Sun, 24 Sep 2006 19:37:04 +0200
Slawomir Nowaczyk <address@hidden> wrote:

#> #> > A simple fix would be to run ispell in some predefined
#> #> > directory, at least on Windows -- c:/ for example. I do not
#> #> > think the location matters for ispell.
#> #> 
#> #> Patches are welcome, but I doubt that it's so easy to find a
#> #> robust directory to run ispell, what with machines that lack a C:
#> #> drive.
#> 
#> Possibly... Are there M$ Windows installations without C: drive?
#> 
#> Anyway, the following patch seems to work on my machines:
#> 
#> **********************************************************************
#> 
#> --- m:/EmacsCVS/EmacsCVS/lisp/textmodes/ispell.el       2006-08-11 
12:45:48.025268800 +0200
#> +++ c:/Emacs/lisp/textmodes/ispell.el   2006-09-24 19:11:05.962598400 +0200
#> @@ -2492,7 +2492,8 @@
#>      (setq ispell-buffer-local-name nil)
#> 
#>      (if ispell-async-processp
#> -       (let ((process-connection-type ispell-use-ptys-p))
#> +       (let ((process-connection-type ispell-use-ptys-p)
#> +              (default-directory (if (member system-type '(cygwin 
windows-nt)) temporary-file-directory default-directory)))
#>           (apply 'start-process
#>                  "ispell" nil ispell-program-name
#>                  "-a"                   ; accept single input lines
#> 
#> **********************************************************************
#> 
#> but I am not 100% sure if temporary-file-directory *always* points to an
#> existing directory... I believe it should, though.
#> 
#> #> The user's home directory might be a better idea, but even that is
#> #> not fool-proof.
#> #> 
#> #> So I think perhaps the code should try c:/ or ~, and if that fails,
#> #> fall back on the current behavior.
#> 
#> Well, if we are really paranoid, the test could be expanded into
#> (and (member system-type '(cygwin windows-nt)) (file-exists-p 
temporary-file-directory))
#> but I do not think it is necessary.
#> 
#> We could, alternatively, use the directory from which emacs.exe is
#> running, but I do not know how to get it.
#> (with-current-buffer "*scratch*" default-directory) would be good enough
#> for me, but I believe it is even less likely to work reliably.

On Sun, 24 Sep 2006 19:37:04 +0200
Slawomir Nowaczyk <address@hidden> wrote:

Here is changelog entry, just in case somebody thinks my patch is good
enough to be installed

2006-09-24  Slawomir Nowaczyk  <address@hidden>

        * ispell.el (ispell-start-process): on windows, do not run
          ispell in a current buffer's directory (it prevented the
          directory from being moved/renamed)

-- 
 Best wishes,
   Slawomir Nowaczyk
     ( address@hidden )

I asked Mom if I was a gifted child...  she said they certainly
wouldn't have paid for me.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]