From unknown Fri Aug 15 14:17:20 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13019: 24.2; ispell: use of local ispell-personal-dictionary Resent-From: Akim Demaille Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 28 Nov 2012 10:20:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 13019 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 13019@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.135409795221753 (code B ref -1); Wed, 28 Nov 2012 10:20:02 +0000 Received: (at submit) by debbugs.gnu.org; 28 Nov 2012 10:19:12 +0000 Received: from localhost ([127.0.0.1]:42626 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TdejX-0005eo-9q for submit@debbugs.gnu.org; Wed, 28 Nov 2012 05:19:12 -0500 Received: from eggs.gnu.org ([208.118.235.92]:53427) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TdejU-0005eg-6T for submit@debbugs.gnu.org; Wed, 28 Nov 2012 05:19:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TdehZ-0005QW-Ux for submit@debbugs.gnu.org; Wed, 28 Nov 2012 05:17:14 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:60253) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TdehZ-0005QR-R3 for submit@debbugs.gnu.org; Wed, 28 Nov 2012 05:17:09 -0500 Received: from eggs.gnu.org ([208.118.235.92]:47253) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TdehT-0001N2-2q for bug-gnu-emacs@gnu.org; Wed, 28 Nov 2012 05:17:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TdehO-0005OR-5k for bug-gnu-emacs@gnu.org; Wed, 28 Nov 2012 05:17:03 -0500 Received: from mail-wg0-f49.google.com ([74.125.82.49]:34456) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TdehN-0005OF-SQ for bug-gnu-emacs@gnu.org; Wed, 28 Nov 2012 05:16:58 -0500 Received: by mail-wg0-f49.google.com with SMTP id gg4so2818350wgb.30 for ; Wed, 28 Nov 2012 02:16:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:content-type:content-transfer-encoding:subject:message-id:date :to:mime-version:x-mailer; bh=iM3zFj1d9ZP1muRMq4R6jE3NZwJsm+7TBCJoquaoH24=; b=xKRGZafC8fQsg0JLnkvc2jXeRqZo6GXY17Q9178KkhmywsWw3GIYTkR99RJpIPr+34 eGAAOOk1/R0AJ7gpV/gHuKcD/NqoDoOQMjmPQ+oceLp05H4ZHw2a+X/pCIHe0YAFP1CK WRE98CMDQjlFLB6PBgibhoISE8pyYgiOgr5ksEU7IRlDQ5O+HU78WSvcssG+GKMeieMj qxn7aQrpkSmxbsgFLkAGZJ6rklWca+kuvH7gl9K1uDFAvCxo7ltjikhYi1oOF4sLs2Ud 2OvzdnllwJqgHcCR65HOWtBk6nKdfebzzCPgRqh4kPpGwhzaZJHBkGTDw4eb1HWnV6jF igzw== Received: by 10.180.78.161 with SMTP id c1mr28403557wix.4.1354097816980; Wed, 28 Nov 2012 02:16:56 -0800 (PST) Received: from mcote-eth.lrde.epita.fr (sao-paulo.lrde.epita.fr. [163.5.55.1]) by mx.google.com with ESMTPS id eu8sm6352493wib.1.2012.11.28.02.16.55 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 28 Nov 2012 02:16:56 -0800 (PST) From: Akim Demaille Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Message-Id: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> Date: Wed, 28 Nov 2012 11:16:53 +0100 Mime-Version: 1.0 (Mac OS X Mail 6.2 \(1499\)) X-Mailer: Apple Mail (2.1499) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -6.1 (------) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) Hi all, I have recently upgraded my Emacs from 22.2.1 to 24.2.1, and there is a feature I lost: I could use ispell-personal-dictionary to specify a per-document *local* (i.e., relative to the directory of the file) dictionary. Consider the following use case: several documents (LaTeX for that matter), with many uncommon words in common. Instead of having a bazillion of (duplicated) "LocalWords:" in all my documents, I have: | %%% Local Variables: | %%% mode: latex | %%% coding: utf-8 | %%% ispell-dictionary: "american" | %%% ispell-personal-dictionary: "../en.dict" | %%% TeX-master: t | %%% fill-column: 76 | %%% End: in each file. This used to work well, i.e., aspell was given the right path to en.dict. With the current version of Emacs, "../en.dict" seems to be resolved relatively to the directory from which Emacs was run, instead of relatively to the document. I do not want to force a full path to the dictionary, because the documents are under VCS, and the dictionary is shared between the authors. I have run the following experiment, on a file with these local variables: | %%% Local Variables: | %%% mode: latex | %%% coding: utf-8 | %%% ispell-dictionary: "american" | %%% ispell-personal-dictionary: "en.dict" | %%% TeX-master: t | %%% fill-column: 76 | %%% End: Of course, what is expected is that en.dict is a local file, "in ./" relatively to the file with these local variables. With Emacs 22, I have the expected behavior: | $ /usr/bin/emacs --version | GNU Emacs 22.1.1 | Copyright (C) 2007 Free Software Foundation, Inc. | GNU Emacs comes with ABSOLUTELY NO WARRANTY. | You may redistribute copies of Emacs | under the terms of the GNU General Public License. | For more information about these matters, see the file named COPYING. | $ /usr/bin/emacs f.tex -- (here, I "M-x ispell", and "C-z" Emacs) |=20 | zsh: suspended /usr/bin/emacs f.tex | $ ps aux | grep aspell | [=85] /opt/local/bin/aspell -a -m -d en_US --encoding=3Dutf-8 -p = /Users/akimd/src/lrde/cours-mob/mob1/src/lecture_2/en.dict As you can see, the location of the en.dict is correct (f.tex is indeed in /Users/akimd/src/lrde/cours-mob/mob1/src/lecture_2). Now with Emacs 24: | $ emacs --version | GNU Emacs 24.2.1 | Copyright (C) 2012 Free Software Foundation, Inc. | GNU Emacs comes with ABSOLUTELY NO WARRANTY. | You may redistribute copies of Emacs | under the terms of the GNU General Public License. | For more information about these matters, see the file named COPYING. | $ emacs mob1/src/lecture_2/f.tex |=20 | zsh: suspended emacs mob1/src/lecture_2/f.tex | $ ps aux | grep aspell | [=85] /opt/local/bin/aspell -a -m -d en_US -p /Users/akimd/en.dict = --encoding=3Dutf-8 this time its completely wrong. The previous behavior was very useful, as it made it possible for a repository of documents to share a dictionary (more useful than per-document Local Words). Yes, there is the "eval" option, but that's working around a bug imho, with the nasty effect that each time the document is opened, you have to validate the action. If "personal" was really meant to be the user's personal data, then it was easy to use "~/" to make it clear, and it is still easy today. On the other hand, the way the dictionary name is turned absolute in 24.2 forbids the previous useful approach. Or have I missed something? Thanks in advance! ---------------------------------------------------------------------- In GNU Emacs 24.2.1 (x86_64-apple-darwin12.2.0) of 2012-11-26 on mcote-eth.lrde.epita.fr Configured using: `configure '--prefix=3D/opt/local' '--without-x' '--without-dbus' '--without-gconf' '--without-libotf' '--without-m17n-flt' '--without-gpm' '--without-gnutls' '--without-xml2' '--infodir' '/opt/local/share/info/emacs' 'CC=3D/usr/bin/clang' 'CFLAGS=3D-pipe -O2 -arch x86_64' 'LDFLAGS=3D-L/opt/local/lib -Wl,-no_pie -arch x86_64' 'CPPFLAGS=3D-I/opt/local/include'' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: fr_FR.UTF-8 value of $XMODIFIERS: nil locale-coding-system: utf-8-unix default enable-multibyte-characters: t Major mode: Fundamental Minor modes in effect: menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Load-path shadows: None found. Features: (shadow sort gnus-util mail-extr emacsbug message idna format-spec rfc822 mml mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail regexp-opt rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils time-date auctex-autoloads tex-site info tool-bar easymenu package tabulated-list uniquify advice help-fns advice-preload ido cus-start cus-load ediff-hook vc-hooks lisp-float-type lisp-mode register page menu-bar rfn-eshadow timer jit-lock font-lock syntax facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer loaddefs button faces cus-face files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote make-network-process multi-tty emacs) From unknown Fri Aug 15 14:17:20 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13019: 24.2; ispell: use of local ispell-personal-dictionary Resent-From: Glenn Morris Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 28 Nov 2012 21:19:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13019 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Akim Demaille Cc: agustin.martin@hispalinux.es, 13019@debbugs.gnu.org Received: via spool by 13019-submit@debbugs.gnu.org id=B13019.13541375353745 (code B ref 13019); Wed, 28 Nov 2012 21:19:01 +0000 Received: (at 13019) by debbugs.gnu.org; 28 Nov 2012 21:18:55 +0000 Received: from localhost ([127.0.0.1]:44123 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tdp1y-0000yM-HH for submit@debbugs.gnu.org; Wed, 28 Nov 2012 16:18:55 -0500 Received: from fencepost.gnu.org ([208.118.235.10]:47258) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tdp1v-0000yD-5H for 13019@debbugs.gnu.org; Wed, 28 Nov 2012 16:18:52 -0500 Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1Tdp01-0002Sm-Iu; Wed, 28 Nov 2012 16:16:53 -0500 From: Glenn Morris References: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> X-Spook: broadside eavesdropping S Box investigation assassinate X-Ran: F|psL1[k'PX~wEC`\TvF3p}sP6A0`6klUtioqj?v%xD_^)lr7n$|AgIPlsS6J]4Y9K)42+ X-Hue: cyan X-Attribution: GM Date: Wed, 28 Nov 2012 16:16:53 -0500 In-Reply-To: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> (Akim Demaille's message of "Wed, 28 Nov 2012 11:16:53 +0100") Message-ID: <8a7gp5tol6.fsf@fencepost.gnu.org> User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -4.6 (----) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.4 (-----) Akim Demaille wrote: > I have recently upgraded my Emacs from 22.2.1 to 24.2.1, and there is > a feature I lost: I could use ispell-personal-dictionary to specify a > per-document *local* (i.e., relative to the directory of the file) > dictionary. Presumably due to 2010-09-02 changes to ispell-init-process for http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6143 Perhaps a file-name-absolute-p check for various variables could be file-local could be added to that. > | %%% ispell-dictionary: "american" > | %%% ispell-personal-dictionary: "../en.dict" From unknown Fri Aug 15 14:17:20 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13019: 24.2; ispell: use of local ispell-personal-dictionary Resent-From: Agustin Martin Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 30 Nov 2012 17:15:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13019 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 13019@debbugs.gnu.org Cc: Akim Demaille Received: via spool by 13019-submit@debbugs.gnu.org id=B13019.13542956483896 (code B ref 13019); Fri, 30 Nov 2012 17:15:02 +0000 Received: (at 13019) by debbugs.gnu.org; 30 Nov 2012 17:14:08 +0000 Received: from localhost ([127.0.0.1]:47238 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeUAB-00010m-LI for submit@debbugs.gnu.org; Fri, 30 Nov 2012 12:14:08 -0500 Received: from fibonacci.ccupm.upm.es ([138.100.198.70]:37432 helo=smtp.upm.es) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeUA9-00010e-5B for 13019@debbugs.gnu.org; Fri, 30 Nov 2012 12:14:06 -0500 Received: from agmartin.aq.upm.es (Agmartin.aq.upm.es [138.100.41.131]) by smtp.upm.es (8.14.3/8.14.3/fibonacci-001) with ESMTP id qAUHBvkv027611; Fri, 30 Nov 2012 18:11:57 +0100 Received: by agmartin.aq.upm.es (Postfix, from userid 1000) id 1E715707; Fri, 30 Nov 2012 18:11:57 +0100 (CET) Date: Fri, 30 Nov 2012 18:11:56 +0100 From: Agustin Martin Message-ID: <20121130171156.GA5521@agmartin.aq.upm.es> References: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> <11368004.8066.1354137417393.JavaMail.root@mx1-new.spamfiltro.es> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <11368004.8066.1354137417393.JavaMail.root@mx1-new.spamfiltro.es> User-Agent: Mutt/1.5.21 (2010-09-15) X-Spam-Score: -1.9 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.2 (---) On Wed, Nov 28, 2012 at 04:16:53PM -0500, Glenn Morris wrote: > Akim Demaille wrote: > > > I have recently upgraded my Emacs from 22.2.1 to 24.2.1, and there is > > a feature I lost: I could use ispell-personal-dictionary to specify a > > per-document *local* (i.e., relative to the directory of the file) > > dictionary. > > Presumably due to 2010-09-02 changes to ispell-init-process for > http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6143 > > Perhaps a file-name-absolute-p check for various variables could be > file-local could be added to that. > > > | %%% ispell-dictionary: "american" > > | %%% ispell-personal-dictionary: "../en.dict" Actual problem happens in `ispell-start-process' where the string to be passed to the spellchecker as personal dictionary is expanded, (if ispell-current-personal-dictionary ; Use specified pers dict. (list "-p" (expand-file-name ispell-current-personal-dictionary))) and is indeed affected by the changes in `default-dictionary' coming from `ispell-init-process`. I think the only reason for that `expand-file-name' is the tilde expansion in non-UNIX systems. In UNIX systems tilde can be explicitly passed. Not sure if the directory {forward,back}slash is also related to this. I am thinking about expanding `ispell-current-personal-dictionary' string only if it contains a tilde prefix. However I am too biassed to the UNIX world. Anyone at the e.g. win32 world can provide info about possible problems with that? -- Agustin From unknown Fri Aug 15 14:17:20 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13019: 24.2; ispell: use of local ispell-personal-dictionary Resent-From: Agustin Martin Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 30 Nov 2012 18:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13019 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 13019@debbugs.gnu.org Cc: Akim Demaille Received: via spool by 13019-submit@debbugs.gnu.org id=B13019.13542985208324 (code B ref 13019); Fri, 30 Nov 2012 18:02:02 +0000 Received: (at 13019) by debbugs.gnu.org; 30 Nov 2012 18:02:00 +0000 Received: from localhost ([127.0.0.1]:47271 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeUuV-0002AD-CP for submit@debbugs.gnu.org; Fri, 30 Nov 2012 13:01:59 -0500 Received: from fibonacci.ccupm.upm.es ([138.100.198.70]:55901 helo=smtp.upm.es) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeUuR-0002A3-KO for 13019@debbugs.gnu.org; Fri, 30 Nov 2012 13:01:57 -0500 Received: from agmartin.aq.upm.es (Agmartin.aq.upm.es [138.100.41.131]) by smtp.upm.es (8.14.3/8.14.3/fibonacci-001) with ESMTP id qAUHxlus000623; Fri, 30 Nov 2012 18:59:47 +0100 Received: by agmartin.aq.upm.es (Postfix, from userid 1000) id 5F605707; Fri, 30 Nov 2012 18:59:47 +0100 (CET) Date: Fri, 30 Nov 2012 18:59:47 +0100 From: Agustin Martin Message-ID: <20121130175947.GA17506@agmartin.aq.upm.es> References: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> <11368004.8066.1354137417393.JavaMail.root@mx1-new.spamfiltro.es> <20121130171156.GA5521@agmartin.aq.upm.es> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="J2SCkAp4GZ/dPZZf" Content-Disposition: inline In-Reply-To: <20121130171156.GA5521@agmartin.aq.upm.es> User-Agent: Mutt/1.5.21 (2010-09-15) X-Spam-Score: -2.7 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.6 (----) --J2SCkAp4GZ/dPZZf Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Fri, Nov 30, 2012 at 06:11:56PM +0100, Agustin Martin wrote: > On Wed, Nov 28, 2012 at 04:16:53PM -0500, Glenn Morris wrote: > > Akim Demaille wrote: > > > > > I have recently upgraded my Emacs from 22.2.1 to 24.2.1, and there is > > > a feature I lost: I could use ispell-personal-dictionary to specify a > > > per-document *local* (i.e., relative to the directory of the file) > > > dictionary. > > > > Presumably due to 2010-09-02 changes to ispell-init-process for > > http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6143 > > > > Perhaps a file-name-absolute-p check for various variables could be > > file-local could be added to that. > > > > > | %%% ispell-dictionary: "american" > > > | %%% ispell-personal-dictionary: "../en.dict" > > Actual problem happens in `ispell-start-process' where the string to be > passed to the spellchecker as personal dictionary is expanded, > > (if ispell-current-personal-dictionary ; Use specified pers dict. > (list "-p" (expand-file-name ispell-current-personal-dictionary))) > > and is indeed affected by the changes in `default-dictionary' coming from > `ispell-init-process`. > > I think the only reason for that `expand-file-name' is the tilde expansion > in non-UNIX systems. In UNIX systems tilde can be explicitly passed. > Not sure if the directory {forward,back}slash is also related to this. > > I am thinking about expanding `ispell-current-personal-dictionary' string > only if it contains a tilde prefix. I am now playing with something different, preserve original value of `default-directory' in `current-ispell-directory' variable and expand personal dictionary after it if no absolute path or tilde is used. I think this is a better approach, see attached patch. Let me test this a bit more before committing. Feel free to test it too. -- Agustin --J2SCkAp4GZ/dPZZf Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="ispell.el_honour-personal-dictionary-path.diff" --- ispell.el.orig 2012-11-30 17:07:14.641701686 +0100 +++ ispell.el 2012-11-30 18:50:08.725283277 +0100 @@ -2669,7 +2669,8 @@ orig-args (if ispell-current-personal-dictionary ; Use specified pers dict. (list "-p" - (expand-file-name ispell-current-personal-dictionary))) + (expand-file-name ispell-current-personal-dictionary + current-ispell-directory))) ;; If we are using recent aspell or hunspell, make sure we use the ;; right encoding for communication. ispell or older aspell/hunspell ;; does not support this. @@ -2706,18 +2707,21 @@ (let* (;; Basename of dictionary used by the spell-checker (dict-bname (or (car (cdr (member "-d" (ispell-get-ispell-args)))) ispell-current-dictionary)) + ;; The directory where process was started. + (current-ispell-directory default-directory) + ;; The default directory for the process. ;; Use "~/" as default-directory unless using Ispell with per-dir ;; personal dictionaries and not in a minibuffer under XEmacs (default-directory (if (or ispell-really-aspell ispell-really-hunspell ;; Protect against bad default-directory - (not (and (file-directory-p default-directory) - (file-readable-p default-directory))) + (not (and (file-directory-p current-ispell-directory) + (file-readable-p current-ispell-directory))) ;; Ispell and per-dir personal dicts available - (not (or (file-readable-p (concat default-directory + (not (or (file-readable-p (concat current-ispell-directory ".ispell_words")) - (file-readable-p (concat default-directory + (file-readable-p (concat current-ispell-directory ".ispell_" (or dict-bname "default"))))) @@ -2725,7 +2729,7 @@ (and (window-minibuffer-p) (not (fboundp 'minibuffer-selected-window)))) (expand-file-name "~/") - (expand-file-name default-directory)))) + (expand-file-name current-ispell-directory)))) ;; Check if process needs restart (if (and ispell-process (eq (ispell-process-status) 'run) --J2SCkAp4GZ/dPZZf-- From unknown Fri Aug 15 14:17:20 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13019: 24.2; ispell: use of local ispell-personal-dictionary Resent-From: Stefan Monnier Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 30 Nov 2012 18:52:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13019 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Agustin Martin Cc: 13019@debbugs.gnu.org, Akim Demaille Received: via spool by 13019-submit@debbugs.gnu.org id=B13019.135430149013186 (code B ref 13019); Fri, 30 Nov 2012 18:52:01 +0000 Received: (at 13019) by debbugs.gnu.org; 30 Nov 2012 18:51:30 +0000 Received: from localhost ([127.0.0.1]:47338 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeVgQ-0003Qd-31 for submit@debbugs.gnu.org; Fri, 30 Nov 2012 13:51:30 -0500 Received: from relais.videotron.ca ([24.201.245.36]:13821) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeVgO-0003QW-Kb for 13019@debbugs.gnu.org; Fri, 30 Nov 2012 13:51:29 -0500 MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; CHARSET=US-ASCII Received: from ceviche.home ([24.201.208.110]) by VL-VM-MR004.ip.videotron.ca (Oracle Communications Messaging Exchange Server 7u4-22.01 64bit (built Apr 21 2011)) with ESMTP id <0MEB00JVGDM7AS10@VL-VM-MR004.ip.videotron.ca> for 13019@debbugs.gnu.org; Fri, 30 Nov 2012 13:49:21 -0500 (EST) Received: by ceviche.home (Postfix, from userid 20848) id E5B1366109; Fri, 30 Nov 2012 13:49:14 -0500 (EST) From: Stefan Monnier Message-id: References: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> <11368004.8066.1354137417393.JavaMail.root@mx1-new.spamfiltro.es> <20121130171156.GA5521@agmartin.aq.upm.es> <20121130175947.GA17506@agmartin.aq.upm.es> Date: Fri, 30 Nov 2012 13:49:14 -0500 In-reply-to: <20121130175947.GA17506@agmartin.aq.upm.es> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-Spam-Score: 1.6 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > I am now playing with something different, preserve original value of > `default-directory' in `current-ispell-directory' variable and expand > personal dictionary after it if no absolute path or tilde is used. [...] Content analysis details: (1.6 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [24.201.245.36 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] 0.1 HDRS_LCASE Odd capitalization of message header 0.0 T_MANY_HDRS_LCASE Odd capitalization of multiple message headers X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > I am now playing with something different, preserve original value of > `default-directory' in `current-ispell-directory' variable and expand > personal dictionary after it if no absolute path or tilde is used. [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [24.201.245.36 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] > I am now playing with something different, preserve original value of > `default-directory' in `current-ispell-directory' variable and expand > personal dictionary after it if no absolute path or tilde is used. IIRC a related issue is whether the ispell process can be kept (rather than killed&restarted) when switching buffer. For my use case, it's fairly important that the ispell process not be killed&restarted unnecessarily and indeed most of my buffers can share the same ispell process because they use no buffer-specific dictionary. Stefan From unknown Fri Aug 15 14:17:20 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13019: 24.2; ispell: use of local ispell-personal-dictionary Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 30 Nov 2012 18:57:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13019 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Agustin Martin Cc: 13019@debbugs.gnu.org, akim.demaille@gmail.com Reply-To: Eli Zaretskii Received: via spool by 13019-submit@debbugs.gnu.org id=B13019.135430177313622 (code B ref 13019); Fri, 30 Nov 2012 18:57:01 +0000 Received: (at 13019) by debbugs.gnu.org; 30 Nov 2012 18:56:13 +0000 Received: from localhost ([127.0.0.1]:47348 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeVkz-0003Xf-0I for submit@debbugs.gnu.org; Fri, 30 Nov 2012 13:56:13 -0500 Received: from mtaout20.012.net.il ([80.179.55.166]:35408) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TeVkw-0003XX-Om for 13019@debbugs.gnu.org; Fri, 30 Nov 2012 13:56:11 -0500 Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0MEB00K00DDKMJ00@a-mtaout20.012.net.il> for 13019@debbugs.gnu.org; Fri, 30 Nov 2012 20:54:02 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MEB00K1HDU1PB00@a-mtaout20.012.net.il>; Fri, 30 Nov 2012 20:54:02 +0200 (IST) Date: Fri, 30 Nov 2012 20:53:48 +0200 From: Eli Zaretskii In-reply-to: <20121130171156.GA5521@agmartin.aq.upm.es> X-012-Sender: halo1@inter.net.il Message-id: <83r4naudkz.fsf@gnu.org> References: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> <11368004.8066.1354137417393.JavaMail.root@mx1-new.spamfiltro.es> <20121130171156.GA5521@agmartin.aq.upm.es> X-Spam-Score: 1.5 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > Date: Fri, 30 Nov 2012 18:11:56 +0100 > From: Agustin Martin > Cc: Akim Demaille > > (if ispell-current-personal-dictionary ; Use specified pers dict. > (list "-p" (expand-file-name ispell-current-personal-dictionary))) > > and is indeed affected by the changes in `default-dictionary' coming from > `ispell-init-process`. > > I think the only reason for that `expand-file-name' is the tilde expansion > in non-UNIX systems. In UNIX systems tilde can be explicitly passed. [...] Content analysis details: (1.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [80.179.55.166 listed in list.dnswl.org] 0.7 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.4964] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 0.7 (/) > Date: Fri, 30 Nov 2012 18:11:56 +0100 > From: Agustin Martin > Cc: Akim Demaille > > (if ispell-current-personal-dictionary ; Use specified pers dict. > (list "-p" (expand-file-name ispell-current-personal-dictionary))) > > and is indeed affected by the changes in `default-dictionary' coming from > `ispell-init-process`. > > I think the only reason for that `expand-file-name' is the tilde expansion > in non-UNIX systems. In UNIX systems tilde can be explicitly passed. You can only reliably pass the tilde to a shell, not to an arbitrary program. From unknown Fri Aug 15 14:17:20 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13019: 24.2; ispell: use of local ispell-personal-dictionary Resent-From: Agustin Martin Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 03 Dec 2012 17:02:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13019 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 13019@debbugs.gnu.org Received: via spool by 13019-submit@debbugs.gnu.org id=B13019.135455411015079 (code B ref 13019); Mon, 03 Dec 2012 17:02:01 +0000 Received: (at 13019) by debbugs.gnu.org; 3 Dec 2012 17:01:50 +0000 Received: from localhost ([127.0.0.1]:51678 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TfZOv-0003vA-T4 for submit@debbugs.gnu.org; Mon, 03 Dec 2012 12:01:50 -0500 Received: from edison.ccupm.upm.es ([138.100.198.71]:42141 helo=smtp.upm.es) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TfZOt-0003v2-GJ for 13019@debbugs.gnu.org; Mon, 03 Dec 2012 12:01:49 -0500 Received: from agmartin.aq.upm.es (Agmartin.aq.upm.es [138.100.41.131]) by smtp.upm.es (8.14.3/8.14.3/edison-001) with ESMTP id qB3GxNxn031237; Mon, 3 Dec 2012 17:59:23 +0100 Received: by agmartin.aq.upm.es (Postfix, from userid 1000) id 240EA55B; Mon, 3 Dec 2012 17:59:23 +0100 (CET) Date: Mon, 3 Dec 2012 17:59:23 +0100 From: Agustin Martin Message-ID: <20121203165922.GA28203@agmartin.aq.upm.es> References: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> <11368004.8066.1354137417393.JavaMail.root@mx1-new.spamfiltro.es> <20121130171156.GA5521@agmartin.aq.upm.es> <20121130175947.GA17506@agmartin.aq.upm.es> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-Spam-Score: -1.5 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.5 (-) On Fri, Nov 30, 2012 at 01:49:14PM -0500, Stefan Monnier wrote: > > I am now playing with something different, preserve original value of > > `default-directory' in `current-ispell-directory' variable and expand > > personal dictionary after it if no absolute path or tilde is used. > > IIRC a related issue is whether the ispell process can be kept (rather > than killed&restarted) when switching buffer. > > For my use case, it's fairly important that the ispell process not be > killed&restarted unnecessarily and indeed most of my buffers can share > the same ispell process because they use no buffer-specific dictionary. I committed a change regarding only with name expansion, but this has some issues regarding ispell process keep/restart, so I am leaving this bug report open until I also deal with this. Former check in personal dictionaries was not in expanded name but in plain string and this will not work well when files are in different directory. At the same time I am noticing some related code that seems redundant, so this will take a bit longer. -- Agustin From unknown Fri Aug 15 14:17:20 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.428 (Entity 5.428) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Akim Demaille Subject: bug#13019: closed (Re: bug#13019: 24.2; ispell: use of local ispell-personal-dictionary) Message-ID: References: <20121203173513.GA7734@agmartin.aq.upm.es> <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> X-Gnu-PR-Message: they-closed 13019 X-Gnu-PR-Package: emacs Reply-To: 13019@debbugs.gnu.org Date: Mon, 03 Dec 2012 17:38:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1354556282-18140-1" This is a multi-part message in MIME format... ------------=_1354556282-18140-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #13019: 24.2; ispell: use of local ispell-personal-dictionary which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 13019@debbugs.gnu.org. --=20 13019: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D13019 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1354556282-18140-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 13019-done) by debbugs.gnu.org; 3 Dec 2012 17:37:43 +0000 Received: from localhost ([127.0.0.1]:51692 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TfZxf-0004i8-EI for submit@debbugs.gnu.org; Mon, 03 Dec 2012 12:37:43 -0500 Received: from edison.ccupm.upm.es ([138.100.198.71]:42995 helo=smtp.upm.es) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TfZxb-0004hy-LU for 13019-done@debbugs.gnu.org; Mon, 03 Dec 2012 12:37:41 -0500 Received: from agmartin.aq.upm.es (Agmartin.aq.upm.es [138.100.41.131]) by smtp.upm.es (8.14.3/8.14.3/edison-001) with ESMTP id qB3HZE7H003772; Mon, 3 Dec 2012 18:35:14 +0100 Received: by agmartin.aq.upm.es (Postfix, from userid 1000) id 026236B1; Mon, 3 Dec 2012 18:35:13 +0100 (CET) Date: Mon, 3 Dec 2012 18:35:13 +0100 From: Agustin Martin To: 13019-done@debbugs.gnu.org Subject: Re: bug#13019: 24.2; ispell: use of local ispell-personal-dictionary Message-ID: <20121203173513.GA7734@agmartin.aq.upm.es> References: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> <11368004.8066.1354137417393.JavaMail.root@mx1-new.spamfiltro.es> <20121130171156.GA5521@agmartin.aq.upm.es> <20121130175947.GA17506@agmartin.aq.upm.es> <20121203165922.GA28203@agmartin.aq.upm.es> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20121203165922.GA28203@agmartin.aq.upm.es> User-Agent: Mutt/1.5.21 (2010-09-15) X-Spam-Score: -1.5 (-) X-Debbugs-Envelope-To: 13019-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.5 (-) On Mon, Dec 03, 2012 at 05:59:23PM +0100, Agustin Martin wrote: > On Fri, Nov 30, 2012 at 01:49:14PM -0500, Stefan Monnier wrote: > > > I am now playing with something different, preserve original value of > > > `default-directory' in `current-ispell-directory' variable and expand > > > personal dictionary after it if no absolute path or tilde is used. > > > > IIRC a related issue is whether the ispell process can be kept (rather > > than killed&restarted) when switching buffer. > > > > For my use case, it's fairly important that the ispell process not be > > killed&restarted unnecessarily and indeed most of my buffers can share > > the same ispell process because they use no buffer-specific dictionary. > > I committed a change regarding only with name expansion, but this has some > issues regarding ispell process keep/restart, so I am leaving this bug > report open until I also deal with this. > > Former check in personal dictionaries was not in expanded name but in plain > string and this will not work well when files are in different directory. At > the same time I am noticing some related code that seems redundant, so this > will take a bit longer. Changes are apparently working very well, so is time for real life check. Committed. Closing bug report. -- Agustin ------------=_1354556282-18140-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 28 Nov 2012 10:19:12 +0000 Received: from localhost ([127.0.0.1]:42626 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TdejX-0005eo-9q for submit@debbugs.gnu.org; Wed, 28 Nov 2012 05:19:12 -0500 Received: from eggs.gnu.org ([208.118.235.92]:53427) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TdejU-0005eg-6T for submit@debbugs.gnu.org; Wed, 28 Nov 2012 05:19:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TdehZ-0005QW-Ux for submit@debbugs.gnu.org; Wed, 28 Nov 2012 05:17:14 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:60253) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TdehZ-0005QR-R3 for submit@debbugs.gnu.org; Wed, 28 Nov 2012 05:17:09 -0500 Received: from eggs.gnu.org ([208.118.235.92]:47253) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TdehT-0001N2-2q for bug-gnu-emacs@gnu.org; Wed, 28 Nov 2012 05:17:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TdehO-0005OR-5k for bug-gnu-emacs@gnu.org; Wed, 28 Nov 2012 05:17:03 -0500 Received: from mail-wg0-f49.google.com ([74.125.82.49]:34456) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TdehN-0005OF-SQ for bug-gnu-emacs@gnu.org; Wed, 28 Nov 2012 05:16:58 -0500 Received: by mail-wg0-f49.google.com with SMTP id gg4so2818350wgb.30 for ; Wed, 28 Nov 2012 02:16:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:content-type:content-transfer-encoding:subject:message-id:date :to:mime-version:x-mailer; bh=iM3zFj1d9ZP1muRMq4R6jE3NZwJsm+7TBCJoquaoH24=; b=xKRGZafC8fQsg0JLnkvc2jXeRqZo6GXY17Q9178KkhmywsWw3GIYTkR99RJpIPr+34 eGAAOOk1/R0AJ7gpV/gHuKcD/NqoDoOQMjmPQ+oceLp05H4ZHw2a+X/pCIHe0YAFP1CK WRE98CMDQjlFLB6PBgibhoISE8pyYgiOgr5ksEU7IRlDQ5O+HU78WSvcssG+GKMeieMj qxn7aQrpkSmxbsgFLkAGZJ6rklWca+kuvH7gl9K1uDFAvCxo7ltjikhYi1oOF4sLs2Ud 2OvzdnllwJqgHcCR65HOWtBk6nKdfebzzCPgRqh4kPpGwhzaZJHBkGTDw4eb1HWnV6jF igzw== Received: by 10.180.78.161 with SMTP id c1mr28403557wix.4.1354097816980; Wed, 28 Nov 2012 02:16:56 -0800 (PST) Received: from mcote-eth.lrde.epita.fr (sao-paulo.lrde.epita.fr. [163.5.55.1]) by mx.google.com with ESMTPS id eu8sm6352493wib.1.2012.11.28.02.16.55 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 28 Nov 2012 02:16:56 -0800 (PST) From: Akim Demaille Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Subject: 24.2; ispell: use of local ispell-personal-dictionary Message-Id: <64FA190B-F4D1-4743-B468-DF2262348DF1@gmail.com> Date: Wed, 28 Nov 2012 11:16:53 +0100 To: bug-gnu-emacs@gnu.org Mime-Version: 1.0 (Mac OS X Mail 6.2 \(1499\)) X-Mailer: Apple Mail (2.1499) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -6.1 (------) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) Hi all, I have recently upgraded my Emacs from 22.2.1 to 24.2.1, and there is a feature I lost: I could use ispell-personal-dictionary to specify a per-document *local* (i.e., relative to the directory of the file) dictionary. Consider the following use case: several documents (LaTeX for that matter), with many uncommon words in common. Instead of having a bazillion of (duplicated) "LocalWords:" in all my documents, I have: | %%% Local Variables: | %%% mode: latex | %%% coding: utf-8 | %%% ispell-dictionary: "american" | %%% ispell-personal-dictionary: "../en.dict" | %%% TeX-master: t | %%% fill-column: 76 | %%% End: in each file. This used to work well, i.e., aspell was given the right path to en.dict. With the current version of Emacs, "../en.dict" seems to be resolved relatively to the directory from which Emacs was run, instead of relatively to the document. I do not want to force a full path to the dictionary, because the documents are under VCS, and the dictionary is shared between the authors. I have run the following experiment, on a file with these local variables: | %%% Local Variables: | %%% mode: latex | %%% coding: utf-8 | %%% ispell-dictionary: "american" | %%% ispell-personal-dictionary: "en.dict" | %%% TeX-master: t | %%% fill-column: 76 | %%% End: Of course, what is expected is that en.dict is a local file, "in ./" relatively to the file with these local variables. With Emacs 22, I have the expected behavior: | $ /usr/bin/emacs --version | GNU Emacs 22.1.1 | Copyright (C) 2007 Free Software Foundation, Inc. | GNU Emacs comes with ABSOLUTELY NO WARRANTY. | You may redistribute copies of Emacs | under the terms of the GNU General Public License. | For more information about these matters, see the file named COPYING. | $ /usr/bin/emacs f.tex -- (here, I "M-x ispell", and "C-z" Emacs) |=20 | zsh: suspended /usr/bin/emacs f.tex | $ ps aux | grep aspell | [=85] /opt/local/bin/aspell -a -m -d en_US --encoding=3Dutf-8 -p = /Users/akimd/src/lrde/cours-mob/mob1/src/lecture_2/en.dict As you can see, the location of the en.dict is correct (f.tex is indeed in /Users/akimd/src/lrde/cours-mob/mob1/src/lecture_2). Now with Emacs 24: | $ emacs --version | GNU Emacs 24.2.1 | Copyright (C) 2012 Free Software Foundation, Inc. | GNU Emacs comes with ABSOLUTELY NO WARRANTY. | You may redistribute copies of Emacs | under the terms of the GNU General Public License. | For more information about these matters, see the file named COPYING. | $ emacs mob1/src/lecture_2/f.tex |=20 | zsh: suspended emacs mob1/src/lecture_2/f.tex | $ ps aux | grep aspell | [=85] /opt/local/bin/aspell -a -m -d en_US -p /Users/akimd/en.dict = --encoding=3Dutf-8 this time its completely wrong. The previous behavior was very useful, as it made it possible for a repository of documents to share a dictionary (more useful than per-document Local Words). Yes, there is the "eval" option, but that's working around a bug imho, with the nasty effect that each time the document is opened, you have to validate the action. If "personal" was really meant to be the user's personal data, then it was easy to use "~/" to make it clear, and it is still easy today. On the other hand, the way the dictionary name is turned absolute in 24.2 forbids the previous useful approach. Or have I missed something? Thanks in advance! ---------------------------------------------------------------------- In GNU Emacs 24.2.1 (x86_64-apple-darwin12.2.0) of 2012-11-26 on mcote-eth.lrde.epita.fr Configured using: `configure '--prefix=3D/opt/local' '--without-x' '--without-dbus' '--without-gconf' '--without-libotf' '--without-m17n-flt' '--without-gpm' '--without-gnutls' '--without-xml2' '--infodir' '/opt/local/share/info/emacs' 'CC=3D/usr/bin/clang' 'CFLAGS=3D-pipe -O2 -arch x86_64' 'LDFLAGS=3D-L/opt/local/lib -Wl,-no_pie -arch x86_64' 'CPPFLAGS=3D-I/opt/local/include'' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: fr_FR.UTF-8 value of $XMODIFIERS: nil locale-coding-system: utf-8-unix default enable-multibyte-characters: t Major mode: Fundamental Minor modes in effect: menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Load-path shadows: None found. Features: (shadow sort gnus-util mail-extr emacsbug message idna format-spec rfc822 mml mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail regexp-opt rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils time-date auctex-autoloads tex-site info tool-bar easymenu package tabulated-list uniquify advice help-fns advice-preload ido cus-start cus-load ediff-hook vc-hooks lisp-float-type lisp-mode register page menu-bar rfn-eshadow timer jit-lock font-lock syntax facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer loaddefs button faces cus-face files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote make-network-process multi-tty emacs) ------------=_1354556282-18140-1--