Thursday, 22 August 2013

Help Needed - Folder Action Script to tar items dropped in folder

Help Needed - Folder Action Script to tar items dropped in folder

I would like to drop/copy files/folders and have them compressed then
copied to my desktop. This is what I know so far...and it isn't much so
any help would be appreciated.
on adding folder items to theFolder after receiving theAddedItems
repeat with x in theAddedItems
This will create my list of files dropped into the folder. Now my
compression command...
tar cvf - *variableForFileListHere* | gzip -9 - > files.tar.gz
Somehow I know I have to feed the list "theAddedItems" created in the
first part of the script to the tar command. But I'm clueless as to how
this might be done. Reading now about tar and it's options as I'm sure
there is an "include" function for pointing to a list of items to add to
the archive. Again any help is appreciated and thanks in advance to anyone
willing to accept this challenge.

No comments:

Post a Comment