Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Sandbox is not allowed to open documents in Terminal

Tags:

macos

Recently I developed an application in Xcode using Swift that starts up the Terminal like this and:

open -a /Application/Utilities/Terminal.app /project/run_stack.sh

After exporting the Application and trying to run it I get this message if my Terminal is running already or I have previously started the same command from the same app (the command is executed through a menu item).

ru_stack.sh can’t be opened because Sandbox is not allowed to open documents in Terminal.

Anyone know why this happens ? If I run it on my Mac it works fine and each time a new terminal starts on the call but when I tried the application on my friend's Mac we get that error in the described cases.

like image 560
wolflegacy Avatar asked Nov 08 '22 16:11

wolflegacy


1 Answers

I was having the same problem. I ended up setting iTerm2 as the "Open With" application for .sh files and that fixed my issue. https://iterm2.com/

like image 182
Michael Maeda Avatar answered Nov 14 '22 22:11

Michael Maeda