Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xcode.activeWorkspaceDocument is nil in branch "MAS-version" #26

Closed
zlit opened this issue Jun 19, 2018 · 4 comments
Closed

xcode.activeWorkspaceDocument is nil in branch "MAS-version" #26

zlit opened this issue Jun 19, 2018 · 4 comments

Comments

@zlit
Copy link

zlit commented Jun 19, 2018

       //InjectionServer.runInBackground
        XcodeApplication *xcode = (XcodeApplication *)[SBApplication
                           applicationWithBundleIdentifier:XcodeBundleID];
        XcodeWorkspaceDocument *workspace = [xcode activeWorkspaceDocument];
        //workspace is nil
        projectFile = workspace.file.path;

but in branch "master" is not nil and work fine. why?

@johnno1962
Copy link
Owner

MAS-branch has the app sandbox switched on for the App Store.

@zlit
Copy link
Author

zlit commented Jun 20, 2018

thanks for your answer.and i found a bug in master branch.

see this commit:
zlit@cfbb13d

I not sure,can i pull request to master branch, It looks like it is not polite.
you said MAS-version branch is experiment,it looks like not very stable.

At last, I not very good in English,i'm sorry for that.

@johnno1962
Copy link
Owner

Hi, Thanks for this. I’ve created a new branch “auto-select-project” from master you can PR this to.

@johnno1962
Copy link
Owner

johnno1962 commented Jun 20, 2018

Perhaps you could make it fall-back to the activeWorkspaceDocument.file.path if it doesn’t find a workspace with the binary's name.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants