Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

AppleScript: Help with copying folder to Library/Application Support

Hi,


I'd like to copy a folder named SMFL from a source folder META FILE in a parent folder named My FOLDER to this destination: "/Library/Application Support/SMuFL/Fonts/" but I can't manage with it...


Actually, the META FILE folder include a folder named SMFL where SMFL contains again a .json file named SMFL.JSON, so I want my folder SMFL to be exactly copied here: "/Library/Application Support/SMuFL/Fonts/"


Below is my code:


tell application "Finder"
	
	activate
	
	set SRCMETA to folder "MY FOLDER:META FILE" of desktop
	
	set thePath to "/Library:Application Support:SMuFL:Fonts"
	
	duplicate every file of SRCMETA to thePath with replacing
	
	
end tel


Thanks a lot for your help, and sorry if I'm making any confusion.

Posted on Jun 21, 2020 2:15 AM

Reply
Question marked as Best answer

I'm not a scripting expert. Two things come to my mind:


First, it could be something related to SIP, since you're trying to modify a system folder.


Second, you could try to manage the copying part through a bash script.

Posted on Jun 21, 2020 2:37 AM

1 reply

AppleScript: Help with copying folder to Library/Application Support

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.