;; things you did not mean to keep. Use M-x desktop-clear RET.
;; Thanks to hetrick@phys.uva.nl (Jim Hetrick) for useful ideas.
-;; avk@rtsg.mot.com (Andrew V. Klein) for a dired tip.
+;; avk@rtsg.mot.com (Andrew V. Klein) for a Dired tip.
;; chris@tecc.co.uk (Chris Boucher) for a mark tip.
;; f89-kam@nada.kth.se (Klas Mellbourn) for a mh-e tip.
;; kifer@cs.stonybrook.edu (M. Kifer) for a bug hunt.
(defcustom desktop-no-desktop-file-hook nil
"Normal hook run when `desktop-read' can't find a desktop file.
Run in the directory in which the desktop file was sought.
-May be used to show a dired buffer."
+May be used to show a Dired buffer."
:type 'hook
:group 'desktop
:version "22.1")
;; This is based on Sebastian Kremer's excellent dired-x.el (Dired Extra),
;; version 1.191, adapted for GNU Emacs. See the `dired-x' Info manual.
-;; At load time dired-x.el will install itself and bind some dired keys.
+;; At load time dired-x.el will install itself and bind some Dired keys.
;; Some dired.el and dired-aux.el functions have extra features if
;; dired-x is loaded.
"Mark files for which PREDICATE returns non-nil.
With a prefix arg, unmark or unflag those files instead.
-PREDICATE is a lisp expression that can refer to the following symbols:
+PREDICATE is a Lisp expression that can refer to the following symbols:
inode [integer] the inode of the file (only for ls -i output)
s [integer] the size of the file for ls -s output
;; functions probably depend on the dired-subdir-alist to be OK.
(defcustom dired-make-directory-clickable t
- "When non-nil, make the directory at the start of the dired buffer clickable."
+ "When non-nil, make the directory at the start of the Dired buffer clickable."
:version "29.1"
:group 'dired
:type 'boolean)
is marked.
If optional third arg SHOW-PROGRESS evaluates to non-nil,
-redisplay the dired buffer after each file is processed.
+redisplay the Dired buffer after each file is processed.
No guarantee is made about the position on the marked line.
BODY must ensure this itself if it depends on this.
;; nil default-directory nil))))))))
(defun dired-file-name-at-point ()
- "Try to get a file name at point in the current dired buffer.
+ "Try to get a file name at point in the current Dired buffer.
This hook is intended to be put in `file-name-at-point-functions'.
Note that it returns an abbreviated name that can't be used
as an argument to `dired-goto-file'."
It has the form (BUFFER DIRED-FILENAME BUFFER-LINE-NUMBER).
WINDOW-POSITIONS are current positions in all windows displaying
-this dired buffer. The window positions have the form (WINDOW
+this Dired buffer. The window positions have the form (WINDOW
DIRED-FILENAME WINDOW-LINE-NUMBER).
We store line numbers instead of point positions because the header
If FILE is non-nil, include only those whose wildcard pattern (if any)
matches FILE.
The list is in reverse order of buffer creation, most recent last.
-As a side effect, killed dired buffers for DIR are removed from
+As a side effect, killed Dired buffers for DIR are removed from
`dired-buffers'."
(setq dir (file-name-as-directory (expand-file-name dir)))
(let (result buf)
(defun dired-buffers-for-dir-or-subdir (dir)
"Return a list of buffers for DIR or a subdirectory thereof.
-As a side effect, killed dired buffers for DIR are removed from
+As a side effect, killed Dired buffers for DIR are removed from
`dired-buffers'."
(setq dir (file-name-as-directory dir))
(let (result buf)
(dired-move-to-filename))
(defun dired-fun-in-all-buffers (directory file fun &rest args)
- "In all buffers dired'ing DIRECTORY, run FUN with ARGS.
+ "In all buffers Dired'ing DIRECTORY, run FUN with ARGS.
If the buffer has a wildcard pattern, check that it matches FILE.
\(FILE does not include a directory component.)
FILE may be nil, in which case ignore it.
;; Delete the entry for FILE from
(defun dired-remove-entry (file)
- "Remove entry FILE in the current dired buffer.
+ "Remove entry FILE in the current Dired buffer.
Note this doesn't delete FILE in the file system.
See `dired-delete-file' in case you wish that."
(save-excursion
(line-beginning-position 2))))))
(defun dired-delete-entry (file)
- "Remove entry FILE in the current dired buffer.
+ "Remove entry FILE in the current Dired buffer.
Like `dired-remove-entry' followed by `dired-clean-up-after-deletion'.
Note this doesn't delete FILE in the file system.
See `dired-delete-file' in case you wish that."
If the current buffer isn't visiting a file, Dired `default-directory'.
If in Dired already, pop up a level and goto old directory's line.
-In case the proper Dired file line cannot be found, refresh the dired
+In case the proper Dired file line cannot be found, refresh the Dired
buffer and try again.
When OTHER-WINDOW is non-nil, jump to Dired buffer in other window.
`kept-old-versions', which tells Emacs how many oldest versions to keep,
and `kept-new-versions', which tells how many newest versions to keep.
Defaults are 2 old versions and 2 new.
-`dired-kept-versions' controls dired's clean-directory (.) command.
+`dired-kept-versions' controls Dired's clean-directory (.) command.
If `delete-old-versions' is nil, system will query user
before trimming versions. Otherwise it does it silently.
This is a cons of two strings (FIND-OPTION . LS-SWITCHES).
FIND-OPTION is the option (or options) passed to `find' to produce
a file listing in the desired format. LS-SWITCHES is a set of
-`ls' switches that tell dired how to parse the output of `find'.
+`ls' switches that tell Dired how to parse the output of `find'.
The two options must be set to compatible values.
For example, to use human-readable file sizes with GNU ls:
;; * nil -- then no buffers are suitable;
;; * a function -- this function is called and the result is used. As
;; an example, if the value is `buffer-file-name' then all buffers
-;; who are visiting files are suitable, but others (like dired
+;; who are visiting files are suitable, but others (like Dired
;; buffers) are not;
;; * a list -- then the buffer is suitable if and only if its mode is in the
;; list, except if the first element is `not', in which case the test
;;; Commentary:
-;; Search a database of files and use dired commands on the result.
+;; Search a database of files and use Dired commands on the result.
;;
;; Locate.el provides an interface to a program which searches a
;; database of file names. By default, this program is the GNU locate
;; character in the file name and the last character in the file name.
;;
;; To use locate-mode, simply type M-x locate and then the string
-;; you wish to find. You can use almost all of the dired commands in
+;; you wish to find. You can use almost all of the Dired commands in
;; the resulting *Locate* buffer. It is worth noting that your commands
;; do not, of course, affect the file database. For example, if you
;; compress a file in the locate buffer, the actual file will be
;;
;;;;;;;; ADVICE For dired-make-relative: ;;;;;;;;;
;;
-;; For certain dired commands to work right, you should also include the
+;; For certain Dired commands to work right, you should also include the
;; following in your _emacs/.emacs:
;;
;; (defadvice dired-make-relative (before set-no-error activate)
(define-derived-mode locate-mode special-mode "Locate"
"Major mode for the `*Locate*' buffer made by \\[locate].
\\<locate-mode-map>\
-In that buffer, you can use almost all the usual dired bindings.
+In that buffer, you can use almost all the usual Dired bindings.
\\[locate-find-directory] visits the directory of the file on the current line.
This function runs `locate-mode-hook' before returning.
(buffer-name)))))
(defun msb-dired-item-handler (_buffer &optional _maxbuf)
- "Create one string item, concerning a dired BUFFER, for the buffer menu.
+ "Create one string item, concerning a Dired BUFFER, for the buffer menu.
The item looks like:
*% <buffer-name>
The `*' appears only if the buffer is marked as modified.
(defun msb-sort-by-directory (item1 item2)
- "Sort the items ITEM1 and ITEM2 by directory name. Made for dired.
+ "Sort the items ITEM1 and ITEM2 by directory name. Made for Dired.
An item look like (NAME . BUFFER)."
(string-lessp (with-current-buffer (cdr item1)
(msb--dired-directory))
(pr-gs-device . (my-gs-device t))
This variable should be modified by customization engine. If this variable is
-modified by other means (for example, a lisp function), use `pr-update-menus'
+modified by other means (for example, a Lisp function), use `pr-update-menus'
function (see it for documentation) to update PostScript printer menu.
Examples:
(set VARIABLE (eval VALUE))
- Note that VALUE can be any valid lisp expression. So, don't
+ Note that VALUE can be any valid Lisp expression. So, don't
forget to quote symbols and constant lists.
If VARIABLE is the special keyword `inherits-from:', VALUE must
be a symbol name setting defined in `pr-setting-database' from
(pr-gs-device . (my-gs-device t))
This variable should be modified by customization engine. If this variable is
-modified by other means (for example, a lisp function), use `pr-update-menus'
+modified by other means (for example, a Lisp function), use `pr-update-menus'
function (see it for documentation) to update PostScript utility menu.
NOTE: Don't forget to download and install the utilities declared on
;; Emacs's traditional method for making buffer names unique adds <2>, <3>,
;; etc. to the end of (all but one of) the buffers. This file replaces
-;; that behavior, for buffers visiting files and dired buffers, with a
+;; that behavior, for buffers visiting files and Dired buffers, with a
;; uniquification that adds parts of the file name until the buffer names
;; are unique. For instance, buffers visiting /u/mernst/tmp/Makefile and
;; /usr/projects/zaphod/Makefile would be named Makefile|tmp and
:type '(choice (const nil) string))
(defcustom uniquify-trailing-separator-p nil
- "If non-nil, add a file name separator to dired buffer names.
+ "If non-nil, add a file name separator to Dired buffer names.
If `uniquify-buffer-name-style' is `forward', add the separator at the end;
if it is `reverse', add the separator at the beginning; otherwise, this
variable is ignored."
;; Dired buffer editable, by changing the buffer mode (which inhibits
;; all of the commands of Dired mode). Here you can edit the names of
;; one or more files and directories, and when you press `C-c C-c',
-;; the renaming takes effect and you are back to dired mode.
+;; the renaming takes effect and you are back to Dired mode.
;;
;; Other things you can do with WDired:
;;
(autoload 'dired-do-create-files-regexp "dired-aux")
(defgroup wdired nil
- "Mode to rename files by editing their names in dired buffers."
+ "Mode to rename files by editing their names in Dired buffers."
:group 'dired)
(defcustom wdired-use-interactive-rename nil
(concat (dired-current-directory) file))))))
(defun wdired-change-to-dired-mode ()
- "Change the mode back to dired."
+ "Change the mode back to Dired."
(or (eq major-mode 'wdired-mode)
(error "Not a Wdired buffer"))
(let ((inhibit-read-only t))
(make-directory (file-name-directory file-new) t)))
(defun wdired-exit ()
- "Exit wdired and return to dired mode.
-Just return to dired mode if there are no changes. Otherwise,
+ "Exit wdired and return to Dired mode.
+Just return to Dired mode if there are no changes. Otherwise,
ask a yes-or-no question whether to save or cancel changes,
and proceed depending on the answer."
(interactive)
;; (add-hook 'dired-mode-hook
;; (lambda ()
;; (define-key dired-mode-map "W" 'woman-dired-find-file)))
-;; and open the directory containing the man page file using dired,
+;; and open the directory containing the man page file using Dired,
;; put the cursor on the file, and press `W'.
;; In each case, the result should (!) be a buffer in Man mode showing
;; manual-browsing facility rather than `WoMan' -- this is
;; intentional!)
-;; (By default, WoMan will automatically define the dired keys "W" and
+;; (By default, WoMan will automatically define the Dired keys "W" and
;; "w" when it loads, but only if they are not already defined. This
;; behavior is controlled by the user option `woman-dired-keys'.
;; Note that the `dired-x' (dired extra) package binds
(woman-dired-define-key key)))
(defun woman-dired-define-keys ()
- "Define dired keys to run WoMan according to `woman-dired-keys'."
+ "Define Dired keys to run WoMan according to `woman-dired-keys'."
(if woman-dired-keys
(if (listp woman-dired-keys)
(mapc #'woman-dired-define-key woman-dired-keys)
;;;###autoload
(defun woman-dired-find-file ()
- "In dired, run the WoMan man-page browser on this file."
+ "In Dired, run the WoMan man-page browser on this file."
(interactive)
(woman-find-file (dired-get-filename)))