1

If I am copying files using dired having previously called (dired-async-mode) to make it copy asynchronously, how do I know when it has successfully finished copying the files?

  • 2
    The status is reported from the mode line, see user option dired-async-message-function, it might be easily missed, since by default it shows for max 3 seconds and disappears immediately if you are hitting some keys. – xuchunyang Jan 25 '17 at 8:34
  • @xuchunyang: Please post your comment as an answer. – Drew Jan 25 '17 at 15:31
1

The final status information of the process is reported on the mode line for 3 seconds, however if you enter some keys during the 3 seconds, it will disappear immediately, thus if you are using Emacs actively, you might miss that easily.

You can change the default behavior via the user option dired-async-message-function. Notes that the corresponding docstring:

Function to use to notify result when operation finish.
Should take same args as `message'.

is not 100% correct, it actually takes (text face &rest args), which is not the same as message. Use the default value as an example, if you want to change it. Here is another example which notifies via voice by using say(1) which provided by macOS.

(setq dired-async-message-function
      (lambda (text face &rest args)
        (shell-command (format "say '%s'" (apply #'format text args)))))

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.