Jump to content

[Request] Sync folders


Recommended Posts

Hi,


I tried to create a sync folder but I'm stuck on the second folder selection.

 

Here is how I think it could work :

 

Type in a keyword then the name of the folder you want to sync with.

Press enter or space then type the folder where you want to sync

Additional options : delete files present in destination folder or not, bidirectional sync

 

Command to use to sync folders with delete files present in dest:

rsync -av -delete source/ destination/

 

Hope someone can help me with with workflow.

 

Thanks in advance!

Link to comment

Hi,

I tried to create a sync folder but I'm stuck on the second folder selection.

 

Here is how I think it could work :

 

Type in a keyword then the name of the folder you want to sync with.

Press enter or space then type the folder where you want to sync

Additional options : delete files present in destination folder or not, bidirectional sync

 

Command to use to sync folders with delete files present in dest:

rsync -av -delete source/ destination/

 

Hope someone can help me with with workflow.

 

Thanks in advance!

 

The way you are talking about doing this may be a little tricky with nothing more than a space between the paths. The reason I say this is, when Alfred passes what you entered into the workflow, its going to be one big string that you would have to parse. With nothing more than a space between them, parsing and delimiting with a space would be out be out because you would have a space in your path name.

 

One way you could do this would be to use a file action and several keywords, and string them together via AppleScript. In this example, you would search, or use the file browser to find the source file and then use Result Actions to start the workflow. Imagine finding the folder, pressing the right arrow and then selecting "Setup Sync" from the options. Then, the Alfred window popping up, pre-filled with a keyword that was a file filter (only shows folder results) where you could once again just type in the name of the folder to search it. Press enter and then the Alfred window shows again allowing you to enter the options. Press enter, and it all executes.

Link to comment

Hum

 

That's become complicated to do for a first workflow :)

 

I will try this later.

 

Anyway thanks for the tip

 

I can still help you do it another way. I was just thinking of the way I would do it. You would just need to select a different character for delimiting the fields. What can I help with?

Link to comment

I'm trying another way by selecting source folder in finder then launch alfredapp with a hotkey then launch a file filter but it doesn't seems to work without a keyword defined. Nothing happens after my hotkey

 

FoehKRd.png

 

bDuYyKW.png

 

but n

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...