From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: "Ehud Karni" Newsgroups: gmane.emacs.help Subject: Re: How to have Emacs ignore Case and list Dirs first with dired-sort-menu Date: Sun, 29 Dec 2002 19:34:40 +0200 Organization: Mivtach-Simon Insurance agencies Sender: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: <200212291734.gBTHYetV006525@beta.mvs.co.il> References: Reply-To: ehud@unix.mvs.co.il NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-8 Content-Transfer-Encoding: 7bit X-Trace: main.gmane.org 1041183499 20925 80.91.224.249 (29 Dec 2002 17:38:19 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Sun, 29 Dec 2002 17:38:19 +0000 (UTC) Cc: help-gnu-emacs@gnu.org Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18ShOD-0005RM-00 for ; Sun, 29 Dec 2002 18:38:18 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18ShNX-000224-00 for gnu-help-gnu-emacs@m.gmane.org; Sun, 29 Dec 2002 12:37:35 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10.13) id 18ShMl-0001bF-00 for help-gnu-emacs@gnu.org; Sun, 29 Dec 2002 12:36:47 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) id 18ShMU-0000kX-00 for help-gnu-emacs@gnu.org; Sun, 29 Dec 2002 12:36:36 -0500 Original-Received: from unix.sw.co.il ([192.114.178.12] helo=unix.mvs.co.il) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18ShMK-00009j-00 for help-gnu-emacs@gnu.org; Sun, 29 Dec 2002 12:36:20 -0500 Original-Received: from beta.mvs.co.il (beta [10.253.0.3]) by unix.mvs.co.il (8.11.6/8.11.6) with ESMTP id gBTHYhh25107; Sun, 29 Dec 2002 19:34:43 +0200 Original-Received: from beta.mvs.co.il (localhost [127.0.0.1]) by beta.mvs.co.il (8.12.5/8.12.5) with ESMTP id gBTHYfed006531; Sun, 29 Dec 2002 19:34:42 +0200 Original-Received: (from ehud@localhost) by beta.mvs.co.il (8.12.5/8.12.5/Submit) id gBTHYetV006525; Sun, 29 Dec 2002 19:34:40 +0200 X-Authentication-Warning: beta.mvs.co.il: ehud set sender to ehud@unix.mvs.co.il using -f Original-To: "Uwe Ziegenhagen" In-reply-to: (message from Uwe Ziegenhagen on Thu, 26 Dec 2002 21:46:28 +0100) X-Mailer: Emacs 21.2.91.3 rmail (send-msg 1.106) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:5115 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:5115 On Thu, 26 Dec 2002 21:46:28 +0100, Uwe Ziegenhagen wrote: > > I even set (setq ls-lisp-dirs-first t) and (setq ls-lisp-ignore-case t), > but this is ignored. > > > (add-hook 'dired-load-hook > (lambda () (load-library "ls-lisp"))) > > [snip] > > ; this should do it, but somehow doesn't work > ; > (setq ls-lisp-dirs-first t) > (setq ls-lisp-ignore-case t) You are setting the variables before their package is loaded. (when `ls-lisp' is loaded they get default values according to your OS). Do something like this: (defun my-dired-changes () "Set my preferences for dired" (require 'ls-lisp) (require 'dired-explore) ;I don't find these (require 'dired-sort-menu) ;packages in 21.2 (setq ls-lisp-dirs-first t) (setq ls-lisp-ignore-case t)) (add-hook 'dired-load-hook 'my-dired-changes) That will load the packages after the `dired' is loaded and THEN set the needed variables. Ehud. -- Ehud Karni Tel: +972-3-7966-561 /"\ Mivtach - Simon Fax: +972-3-7966-667 \ / ASCII Ribbon Campaign Insurance agencies (USA) voice mail and X Against HTML Mail http://www.mvs.co.il FAX: 1-815-5509341 / \ mailto:ehud@unix.mvs.co.il Better Safe Than Sorry