I regularly use shell files to execute tasks on my Mac quicker.
I just upgraded to MacOS Monterey today, and since then, any shell files I have created, will not execute. Every time I double click on their icon, I get
zsh: operation not permitted
.
I have given the files proper executable permissions with
chmod +x my-file.sh
and
chmod a+x my-file.sh
and
chmod u+x my-file.sh
,
but none of those work. Shell files I have created in the past still work fine, but it is just new ones that do not.
Terminal has full disk access in System Preferences.
I am stuck, and I don't know what to do, because I use shell files regularly. If anybody has any idea what's going on, any help would be appreciated.
sudo su
before creating new files. What doesls -la
say? Check the privileges and file owners. Where do you store your files?/path/to/my-file.sh
or you also get anoperation not permitted
error?