Closed ky1ejs closed 6 years ago
Hey, just wanted to let you know I did see this issue, as well as the pull requests you've opened. Thanks for these!
I'm a bit busy at the moment, so I haven't had time to look at these in detail. I hope to do that later next week.
Also, in case you hadn't seen it, I'm working on a serialization feature (https://github.com/tomlokhorst/Xcode.swift/pull/4) that itself is also a major refactor of the codebase. This feature is needed for a future version of R.swift, so I do plan on completing it.
Awwwesssommmeee!! Can I help in anyway with your refactor? Are there any tasks on the list you've made that I could take care of for you?
I've been using Xcode.swift in a command line application we've been making. We're using it to pass project, scheme and target data to
xcodebuild
.It would be really handy if XCProjectFile stored the name and URL of the Xcode project it pointed to so that it could be retrieved later (we'd pass it to
xcodebuild
).I've already tried making this refactor, but I'm finding it quite complicated to do because of the way the code is architected. For example, if a
url: NSURL
property were to be added to theXCProjectFile
class then all the initialisers would have to take an NSURL parameter. When I considered this it came to me that the initialisers inXCProjectFile
class that don't take anNSURL
, actually belong in thePBXProject
class as they actually provide initialisation for thePBXProject
class, not theXCProjectFile
.I'd like to suggest quite a significant refactor to Xcode.swift to simplify future kinds of refactors like this, and improve encapsulation. I'm very conscious that this might not be something you're interested in doing because of the amount of work it presents :sweat_smile:, but I think it would greatly improve Xcode.swift, and make it easier for other contributors in the future. And of course I'd be more than happy to help! :smile:
I think this is a great project, and I'd much rather contribute to your work so far rather than create a duplicate :smile:. I've committed my attempt so far at adding a project name to
XCProjectFile
here to give an idea of the challenges. It'd be great to discuss different approaches to Xcode.swift's architecture.Let me know what you think! :)