In the past it used to be easy to install CommandLineTools without Xcode. Now I cannot get it to install correctly. Please note: this is not a development question but an installation of software question.
There are many discussions of similar issues, but none exactly what I am seeing.
A short answer to my question would be "it is no longer possible to run CommandLineTools unless full Xcode is installed". I am hoping that is not the case.
I have tried many variations on all the suggested steps, along with attempts at clean uninstallation and starting over. I have gleaned a lot of steps from the following sources:
And likely more pages that I did not record.
I have installed Xcode, uninstalled it, installed and uninstalled standalone CommandLineTools, used xcode-select --switch, and more, all in various combinations.
The result is that when full Xcode is not installed, when trying to run a command, I get the following error message or similar, depending upon the command:
xcode-select: error: tool 'opendiff' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance
With full Xcode, the commands work.
In many places in the threads mentioned above, people complain about having to have 6GB of unwanted code; this is no longer incorrect. The current version of Xcode is now 10GB.
My main use of the CommandLineTools is to support MacPorts. As a bonus I like opendiff in some cases where my main tools are farther out of reach.
Is there a solution to this issue?
EDIT: I see that Apple now provides a direct way of installed Command Lines Tools only as Command_Line_Tools_macOS_10.13_for_Xcode_9.4, but it is only for High Sierra. While I am still a hold out to the upgrade to HS, it will be only a very short time before I do this upgrade. Hoping that is the line of least resistance.