I was using an older version of this script and eventually it stopped working because it was only designed to work for macOS version 10, and didn't anticipate version 11 or 12 being released.
In order to prevent that from happening again in a year or two, this pull request removes the hardcoded version numbers and uses a more general regular expression to find SDKs. Additionally, I fixed it so that an error message is shown if no SDKs are found, which was the original intent of the code.
I was using an older version of this script and eventually it stopped working because it was only designed to work for macOS version 10, and didn't anticipate version 11 or 12 being released.
In order to prevent that from happening again in a year or two, this pull request removes the hardcoded version numbers and uses a more general regular expression to find SDKs. Additionally, I fixed it so that an error message is shown if no SDKs are found, which was the original intent of the code.