'Persist accessibility permissions between builds in xcode 13

I am building a window manager that requires the use of the Accessibility API for macOS. My code works fine if I build the app, grant the debug build accessibility permissions in the Security and Privacy panel, and then run my code. But if I change any code, I have to regrant the permissions manually and it is incredibly laborious to do between each build.

How can I persist the permissions between builds? I see this is an issue elsewhere and I have tried all the tactics I found on Stack Overflow so far.



Solution 1:[1]

I got to where I needed to be. This seems to work.

declare

 dbname varchar2(200);

 sqlstmp varchar2(500);

begin

 select name into dbname from v$database;

 sqlstmp := 'create pfile=''/tmp/'|| dbname ||'/'||dbname||'init.ora'' from spfile';

execute immediate (sqlstmp);

end;

/

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 goswell