Is there a way to remove the authorization prompt from command-line instances of Instruments (Xcode)?

前端 未结 11 1035
南笙
南笙 2020-12-02 07:53

I am currently using Instruments via a bash script to initiate the command-line interface to start up runs of the Automation plug-in.

With 4.2, this worked well en

11条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-02 08:35

    The user your script runs as has to be authorized to use the developer tools. You can do this two ways:

    • Add the user to the _developer group: sudo dscl . append /Groups/_developer GroupMembership scriptusername

    • Use the DevToolsSecurity command line tool

    Keep in mind that for the UIAutomation instruments to work properly, the user you are invoking Instruments from will also need to be a user that can start a window server (i.e. run the UI) - and will have to be logged in to a window server when UIAutomation runs.

    These two things are two of the four or five secrets to using UIAutomation with Jenkins.

提交回复
热议问题