Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How do I set up a shortcut to sync two fixed locations? #30

Open
SreenivasVRao opened this issue Aug 26, 2020 · 1 comment
Open

How do I set up a shortcut to sync two fixed locations? #30

SreenivasVRao opened this issue Aug 26, 2020 · 1 comment
Labels
question Further information is requested

Comments

@SreenivasVRao
Copy link

I would like to have a way to sync two directories

so something like

(defun my-dired-sync-workflow(src dst) ...)

(global-set-key (kbd ...) 'my-dired-sync-workflow)

and probably have a set of fixed values for src and dst - I'm thinking of using some hacky setq for now since I only have one src and dst pair I care about.

@stsquad stsquad added the question Further information is requested label Aug 27, 2020
@stsquad
Copy link
Owner

stsquad commented Aug 27, 2020

You could probably hack something up by let binding dired-rsync-source-files to provide your list of files and then calling dired-rsync. Something like (untested):

(defun my-dired-rsync-workflow()
  (interactive)
  (let ((dired-rsync-source-files (lambda()
                                    "tramp-path-from-source")))
    (dired-rsync "tramp-path-to-dest")))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants