I just sussed out the following:
tell application "Xcode"
set t to name of front window
set o to offset of " — " in t
if o > 0 then set t to text 1 thru (o - 1) of t
set d to source document named t
end tell
It works in Xcode 11 & 12, with stand-alone file windows, files opened in tabs in a workspace document, and assistent windows.
Post
Replies
Boosts
Views
Activity
In another thread, PBK said the sandbox user never gets an email: https://developer.apple.com/forums/thread/72083?answerId=215874022#215874022
If that's true, there's no need to use an address that you can receive email at.
We have the same issue, in the unit-tests of a swift-package. In our case, moving the tests to a test target under the sample app didn't help. FB8885728.