Please create it before running this script." set dropboxAppSupportFolder to (path to home folder as text) & "Dropbox:Library:Application Support:"Įrror "The dropbox application support folder does not exist. ![]() I would write that script like this… notice that the Finder is only needed for one line of the script so we do not “tell application Finder” to do everything, we only tell it to do that one line. The main problem that I see with your “ln” command is that it has no spaces in it (you need spaces between the paths and also the ln command) and the source path should come before the destination path. If I’m understanding your situation, I think you want to select a folder in your user’s application support folder and have a symbolic link for that folder created in your dropbox application support folder. – Shell Script to create symbolic link do shell script "ln -s" & quoted form of POSIX path of dropboxfolder & quoted form of POSIX path of localfolder Set dropboxfolder to choose folder default location (path to home folder) with prompt "Now Select the DropBox Application Support Folder:"ĭisplay dialog "Error: " & errNum & return & errMsg – Set vairables and select the source and destination folders and then move the folder set localfolder to choose folder default location (path to home folder) with prompt "Select Original Application Support Folder:" – Just a pop-up to explain whats going to happen.ĭisplay dialog “This script will move a selected folder to a specified location, then create a symbolic link from the original location” Ln -sv /Users/username/Dropbox/Library/Application\ Support/Adium\ 2.0/ ~/Library/Application\ Support/Adium 2.0 The script that works directly in terminal for reference: Not sure how to do this, found a few examples with if statement but cannot figure out how to integrate it into this script.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |