11

Mac OS X V. 10.9.4 2.4 GHz 2 GB RAM

Im trying to use Git through my mac terminal and it keeps returning this error every time I submit a git command: "xcrun: error: unable to exec Xcode native xcrun (Exec format error).".

I already installed git and github in my mac. Im somehow new to programming I i don't really understand whats causing this error. Its getting very frustrating.

Daniel
  • 111
  • 1
  • 4
  • see http://stackoverflow.com/questions/11977648/xcrun-error-failed-to-exec-real-xcrun-no-such-file-or-directory – jub0bs Aug 21 '14 at 07:52

3 Answers3

22

The following works for me:

sudo xcode-select --reset
bfontaine
  • 18,169
  • 13
  • 73
  • 107
0

The GUI equivalent of this is to log into the machine, open Xcode, go to preferences, locations, and set the active command line tools version of xcode

ShowPony
  • 162
  • 1
  • 4
0

I was getting a similar xcrun: error: unable to exec Xcode native xcrun (Not a directory). on my mac which is managed by a central admin. I had to run my command with sudo.

Loopy
  • 63
  • 8