I'm using Flutter for creating app and I need to run a file with arguments from dart code (This file is in the app's container) on MacOS. How can I do it in a sandbox? I don't want to disable sandbox because then i can't publish app in App Store.
I tried this code ProcessResult result = await Process.run(path, [-pa], includeParentEnvironment: true);
but I'm getting error: ProcessException: Operation not permitted.
Also, I saw thing called "Embedding a command-line tool in a sandboxed app", but I don't know how to do it in my case.