Jump to content

chronosync workflow help


Recommended Posts

Posted

I only know bits of code from participating in this forum and brute force trying to learn things. I’m hoping that I can turn this request for help into a learning experience. I use chronosync for my regular backups and I would like to trigger some of them through alfred. Chronosync can be scripted via applescript and what I would like to do is have my workflow return a list of my chronosync documents (they live in a specific directory), select one and have that document be passed as a argument/variable so it can be run in a applescript that runs the backup.


I know that running 'ls' on the directory where my sync documents are stored will return a list of those files, but this is where my knowledge stops but i would imagine this workflow could run in script filter to do the following:

- return list of chronosync documents
- document is chosen from list
- that document is passed as argument to chronosync applescript 

 

I imagine some my answers lie here and this moom workflow I use regularly appears to do something similar except the moom snapshots are returned via applescript instead of pulling files from a directory.

 

I would be appreciative of something that might get me started... maybe another workflow in the gallery that does something similar so I can try and learn what it is doing? I'm a total novice. And if anyone is wondering I'm totally using this as a form of procrastination as I should be doing something else with this time.

 

 

Posted

The workflow @Stephen_C listed is probably closer to what you want, but still it occurred to me a way to do something similar without code. You could use the Folder Contents Automation Task, which is better than ls because the former gives all contents as individual arguments while the latter gives you a long string of one argument you’d need to split. Then connect it directly to the Grid View et voilà, instant listing of the entries.

Posted
6 minutes ago, vitor said:

You could use the Folder Contents Automation Task, which is better than ls because the former gives all contents as individual arguments while the latter gives you a long string of one argument you’d need to split. Then connect it directly to the Grid View et voilà, instant listing of the entries.

That, of course, is very neat. 😀 There's always a better way and you always know it!

 

Stephen

Posted

Currently I have a list filter that passes the argument to my applescript which does the trick but procrastination on other projects seemed to be the ideal time to try and lose half a day trying to learn something new. I would like to learn some JSON/script filter stuff so I can be a little fancier.... 

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...