Take a look at automater it is included in 10.4 and you can use to create a script that would watch a folder and do something when a file appears - like upload it. -- John Pattenden Screentime Media - Flash Tools since 1997 http://www.screentime.com
Automator is pretty weak, and you can't export Automator workflows as scripts to attach as folder actions, as far as I know. I guess until we get some application scripting support in the Adobe Suite we can't use Dreamweaver for automatic uploads. The rabbit hole goes pretty deep.. terminal and lftp and so on... Bleh.. Here's an easy, fool proof way I found using Transmit and Applescript that takes only a minute to set up and seconds to reconfigure.. So to automatically upload a swf to your server from a flash publish.. ? Create a new folder to trigger the upload. ? Set Flash to publish the HTML (or another format you don't need) to the folder you created. ? Open Transmit, and create a favorite that opens the site and remote directory of the file you are replacing... ? Set Transmit's File Transfer preferences to automatically replace existing uploads. (You can probably supress this dialog using script as well?) ?Create a new script using script editor.. Copy paste the following script, it's an adaption of examples provided at Transmit's support pages (transmit.com/support) drag and drop the file you wish to upload in place of the file, and change the nickname of the favorite you created. on adding folder items to this_folder after receiving these_items activate application "Transmit" tell application "Transmit" make new document at before front document tell document 1 tell session 1 if (connect to favorite with name "mySite") then try upload item "/Users/bsmith/Sites/mySite/my.swf" end try else display dialog ("An error occured, could not connect to favorite") end if disconnect end tell end tell end tell end adding folder items to
oops, we have to delete the contents of the trigger folder, or the folder action does know when Flash is done with the Publish. Update the end of the code to look like this: activate application "Finder" tell application "Finder" delete these_items end tell end adding folder items to
Don't see what you're looking for? Try a search.
|