git:错误:无法找到SDK“macosx”

时间:2015-05-22 04:55:51

标签: macos git osx-yosemite

刚刚将我的机器更新为Yosemite。我现在从Git收到这个错误:

    // Calculations for money denomination//
    float dollar = floor(total);
        total = total-dollar;
    float quarter = floor(total/.25);
        total= total -(quarter*.25);
    float dime = floor(total/.1);
        total = total-(dime*.1);
    float nickel = floor(total/.05);
        total = total-(total*.05);
    float penny = floor(total/.01);
        total = total-(total*.01);

我可以毫无问题地运行$('input:radio').click(function() { var idAttr = $(this).attr('id'); alert(idAttr); }); ,但git: error: SDK "macosx" cannot be located 之类的东西似乎有效,但随后会抛出此错误。安装了命令行工具,我尝试重新安装Git。

2 个答案:

答案 0 :(得分:17)

Not sure exactly what, but something got out of whack during the upgrade. Uninstall CommandLineTools by typing sudo rm -r /Library/Developer/CommandLineTools then reinstall. I just typed some git command like: git status and let the OS prompt me to install the CommandLineTools. Everything is happy now.

答案 1 :(得分:0)

我还得到了git: error: SDK "macosx" cannot be located,该页面将我引向了此页面。

我也收到类似“打开太多文件”和“无法分叉”的消息。

解决Spotify问题已解决。我没有重新安装Git。