pkc
pkc

Reputation: 8504

Carthage requires git 2.3.0 or later

I am using charts library and trying to run the demo. Before running I have to install the dependencies using Carthage. I goto project folder location and type in terminal:

carthage update

I got the below error:-

Carthage requires git 2.3.0 or later.

How to install Carthage decencies and run the above said demo.

enter image description here

Upvotes: 10

Views: 5594

Answers (4)

Lal Krishna
Lal Krishna

Reputation: 16160

Select Command Line Tools to the latest version of Xcode.

Xcode -> Preferences -> Locations -> Command Line Tools

Open Preferences shortcut : Command + comma + ,

Upvotes: 25

NanDotWang
NanDotWang

Reputation: 41

Not sure if this will help, but I ran into the same issue and found out that xcodebuild is using a different Xcode that I installed.

so you can probably double check which Xcode you are using: xcode-select --print-path

Here is the original post that helped me solving this issue: Change Carthage Swift version

Upvotes: 4

Eridana
Eridana

Reputation: 2408

It seems you have to install new version of git.

brew install git

It could say "Target /usr/local/bin/git already exists. You may want to remove it". I didn't want to remove it and decided only to overwrite:

brew link --overwrite git

It helped me with the same issue. I hope it will help to someone else.

Upvotes: 1

Mojtaba Hosseini
Mojtaba Hosseini

Reputation: 119302

It seems like you have used another Xcode version since last time. You should set command line tool again by running the following in terminal:

sudo xcode-select -s <path to Xcode>/Contents/Developer 

for example:

sudo xcode-select -s /Applications/Xcode.app/Contents/Developer 

Upvotes: 5

Related Questions