Mercurial > emacs
comparison lisp/dired-aux.el @ 55993:7f35f020d8d8
(dired-do-touch, dired-clean-directory, dired-run-shell-command)
(dired-query): Add autoloads.
author | Luc Teirlinck <teirllm@auburn.edu> |
---|---|
date | Wed, 09 Jun 2004 01:04:28 +0000 |
parents | b711ea364657 |
children | def58a71f49d |
comparison
equal
deleted
inserted
replaced
55992:b711ea364657 | 55993:7f35f020d8d8 |
---|---|
253 (interactive "P") | 253 (interactive "P") |
254 (if (memq system-type '(ms-dos windows-nt)) | 254 (if (memq system-type '(ms-dos windows-nt)) |
255 (error "chown not supported on this system")) | 255 (error "chown not supported on this system")) |
256 (dired-do-chxxx "Owner" dired-chown-program 'chown arg)) | 256 (dired-do-chxxx "Owner" dired-chown-program 'chown arg)) |
257 | 257 |
258 ;;;###autoload | |
258 (defun dired-do-touch (&optional arg) | 259 (defun dired-do-touch (&optional arg) |
259 "Change the timestamp of the marked (or next ARG) files. | 260 "Change the timestamp of the marked (or next ARG) files. |
260 This calls touch." | 261 This calls touch." |
261 (interactive "P") | 262 (interactive "P") |
262 (dired-do-chxxx "Timestamp" dired-touch-program 'touch arg)) | 263 (dired-do-chxxx "Timestamp" dired-touch-program 'touch arg)) |
340 | 341 |
341 ;;; Cleaning a directory: flagging some backups for deletion. | 342 ;;; Cleaning a directory: flagging some backups for deletion. |
342 | 343 |
343 (defvar dired-file-version-alist) | 344 (defvar dired-file-version-alist) |
344 | 345 |
346 ;;;###autoload | |
345 (defun dired-clean-directory (keep) | 347 (defun dired-clean-directory (keep) |
346 "Flag numerical backups for deletion. | 348 "Flag numerical backups for deletion. |
347 Spares `dired-kept-versions' latest versions, and `kept-old-versions' oldest. | 349 Spares `dired-kept-versions' latest versions, and `kept-old-versions' oldest. |
348 Positive prefix arg KEEP overrides `dired-kept-versions'; | 350 Positive prefix arg KEEP overrides `dired-kept-versions'; |
349 Negative prefix arg KEEP overrides `kept-old-versions' with KEEP made positive. | 351 Negative prefix arg KEEP overrides `kept-old-versions' with KEEP made positive. |
549 (if (> (length file-list) 1) | 551 (if (> (length file-list) 1) |
550 (setq files (concat dired-mark-prefix files dired-mark-postfix))) | 552 (setq files (concat dired-mark-prefix files dired-mark-postfix))) |
551 (funcall stuff-it files))))) | 553 (funcall stuff-it files))))) |
552 | 554 |
553 ;; This is an extra function so that it can be redefined by ange-ftp. | 555 ;; This is an extra function so that it can be redefined by ange-ftp. |
556 ;;;###autoload | |
554 (defun dired-run-shell-command (command) | 557 (defun dired-run-shell-command (command) |
555 (let ((handler | 558 (let ((handler |
556 (find-file-name-handler (directory-file-name default-directory) | 559 (find-file-name-handler (directory-file-name default-directory) |
557 'shell-command))) | 560 'shell-command))) |
558 (if handler (apply handler 'shell-command (list command)) | 561 (if handler (apply handler 'shell-command (list command)) |
803 (?! . yes) ; `!' accepts rest | 806 (?! . yes) ; `!' accepts rest |
804 (?q . no) (?\e . no) ; `q' or ESC skips rest | 807 (?q . no) (?\e . no) ; `q' or ESC skips rest |
805 ;; None of these keys quit - use C-g for that. | 808 ;; None of these keys quit - use C-g for that. |
806 )) | 809 )) |
807 | 810 |
811 ;;;###autoload | |
808 (defun dired-query (qs-var qs-prompt &rest qs-args) | 812 (defun dired-query (qs-var qs-prompt &rest qs-args) |
809 ;; Query user and return nil or t. | 813 ;; Query user and return nil or t. |
810 ;; Store answer in symbol VAR (which must initially be bound to nil). | 814 ;; Store answer in symbol VAR (which must initially be bound to nil). |
811 ;; Format PROMPT with ARGS. | 815 ;; Format PROMPT with ARGS. |
812 ;; Binding variable help-form will help the user who types the help key. | 816 ;; Binding variable help-form will help the user who types the help key. |