unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* dired-jump
@ 2006-07-08  1:11 Miles Bader
  2006-07-08  2:16 ` dired-jump Leon
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: Miles Bader @ 2006-07-08  1:11 UTC (permalink / raw)


I just found out about a very very handy binding (thanks to David
Kastrup's comment on another mailing list): C-x C-j  -- dired-jump
(which when given in a file buffer, pops up a dired  buffer on its
directory with point positioned over the entry for that file).

Unfortunately this only gets bound if you load dired-x.el.

This seems so handy that I think it really ought to be bound by default
(`dired-jump' is already autoloaded from dired-x.el) -- having global
non-mode-specific bindings take effect only when you load a particular
lisp file seems most peculiar when that file is part of the standard
lisp distribution.

The code which binds dired-jump to `C-x C-j' is conditional upon the
variable `dired-bind-jump' -- if that variable is nil, then the binding
is not done.

We could simply continue honoring `dired-bind-jump', but move the
binding code from dired-x.el to bindings.el (and maybe add a bit of
customize magic to make changes to `dired-bind-jump' do something
intelligent).  [If bindings.el is executed before dumping, perhaps this
code would need to be put somewhere that happens after loading the
user's init file...]

Here's the code from dired-x.el:

   ;;; GLOBAL BINDING.
   (if dired-bind-jump
       (progn
         (define-key global-map "\C-x\C-j" 'dired-jump)
         (define-key global-map "\C-x4\C-j" 'dired-jump-other-window)))


What do people think?

-Miles

-- 
o The existentialist, not having a pillow, goes everywhere with the book by
  Sullivan, _I am going to spit on your graves_.

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

end of thread, other threads:[~2006-07-08 20:57 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-08  1:11 dired-jump Miles Bader
2006-07-08  2:16 ` dired-jump Leon
2006-07-08  3:41 ` dired-jump Drew Adams
2006-07-08  8:29 ` dired-jump David Kastrup
2006-07-08  8:57 ` dired-jump Romain Francoise
2006-07-08 20:57   ` dired-jump Richard Stallman
2006-07-08 15:31 ` dired-jump Richard Stallman

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

	https://git.savannah.gnu.org/cgit/emacs.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).