mac do you need both xcode and command line tools code example
Example 1: check xcode version on mac terminal
/usr/bin/xcodebuild -version
Example 2: list xcode version on mac
xcodebuild -version
/usr/bin/xcodebuild -version
xcodebuild -version