I need to run a simple command like this:
do shell script "sudo cp -r /Users/me/file.plugin /Library/My-Plug-Ins" with administrator privileges
However I get "operation not permitted", with or withou sudo.
error "cp: /Users/me/file.plugin: unable to copy extended attributes to /Library/My-Plug-Ins/file.plugin: Operation not permitted cp: /Users/me/file.plugin: Operation not permitted" number 1
I know the file exists and I know I can copy it with c++ code; however, I want something that will look more "seamless" and not have an issue so I'd prefer applescript or something more professional than a terminal window?
Currently on MacOs Monterey
man cpdoesn't list an -r flag, but an -R flag.