Skip to content

Instantly share code, notes, and snippets.

View kerker00's full-sized avatar

Markus Müller kerker00

View GitHub Profile
@rtrouton
rtrouton / gist:f92f263414aaeb946e54
Last active May 30, 2021 12:32
Install Xcode command line tools on 10.7.x - 10.10.x. Tested on 10.7.5, 10.8.5, 10.9.5 and 10.10.2.
#!/bin/bash
# Installing the Xcode command line tools on 10.7.x or higher
osx_vers=$(sw_vers -productVersion | awk -F "." '{print $2}')
cmd_line_tools_temp_file="/tmp/.com.apple.dt.CommandLineTools.installondemand.in-progress"
# Installing the latest Xcode command line tools on 10.9.x or higher
if [[ "$osx_vers" -ge 9 ]]; then