I use two Dired Emacs buffers, juxtaposed in two vertical panels to copy files from my local computer to a distant server (over SCP). I hit Ctrl + C to copy the local file and give the path to the distant server repository. Thought, it's a pain because you constantly have to switch from one buffer to another to browse their content.

Is it possible to synchronize the two buffers, assuming the tree repository are the same on my local machine and on the server. I know it is possible using WinSCP with the Synchronized Browsing feature turned on. Édit : Filezilla also provides this feature.

Maybe Sunrise Commander could be the right tool but I don't have tested it yet.

I don't need a graphical tool.


It is definitely possible and not too hard using the Sunrise Commander and tramp (which is included by default in all GNU Emacs distributions, AFAIK).

Have a look here for tips on how to compare directories in SC, either superficially or recursively. Once you have the entries that differ in each directory, you can apply to them whatever operation you need.


If you are using Emacs 23.2 or later, see user option dired-auto-revert-buffer and auto-revert-mode.

The former refreshes a Dired buffer whenever you visit it. The latter refreshes buffers periodically.

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.