Closed vinayjn closed 4 years ago
@twostraws the idea behind using different files was to remove hardcoded values from logical components. I liked the idea of directly flattening the regex data into a consumable os version string. I'll make the change. 👍
@twostraws have a look at the updated code.
This is a great first implementation, thanks!
simctl
has a way to get more information about those identifiers be running simctl list runtimes -j
. That will dump out some data of the available runtimes with all of this nicely parsed already.
However, there might be some times where we still need to parse the identifier directly and we could fall back to the RegEx.
FYI @vinayjn - when #19 gets merged, the SimCtl.Simulator
type will have a new runtimeTypeIdentifier
string that can be used to match things up a bit more easily.
@davedelong thanks for the update, I have made the required changes. Please have a look. Thanks
Thank you very much – this is a great change, and you put in lots of extra work to make it right 👍
This is a really great change – thank you! The regex seems very precise, so I'm wondering if it really adds anything other than just using replacingOccurrences to strip out the prefix, replacing "OS-" with "OS ", then replacing any dashes with dots? We could then flatten the data to a string, which would remove Constants.swift, Extensions.swift, and
OSInfo
.