---
title: "#11: Carthage 🗿"
url: https://littlebitesofcocoa.com/11-carthage
author: Jake Marsh
published: 2015-06-01
topics: ["Tools","Libraries"]
description: "Carthage is a new way to integrate third-party libraries in your apps. One way to think of it is as a simpler alternative to CocoaPods."
---

# #11: Carthage 🗿

By Jake Marsh, June 1, 2015. HTML: https://littlebitesofcocoa.com/11-carthage

**Carthage** is a new way to integrate third-party libraries in your apps. One way to think of it is as a simpler alternative to **CocoaPods**. It’s a dependency manager distilled down to just about it’s simplest possible form.

One of the notable differences between **Carthage** and **CocoaPods** is that **Carthage** doesn’t require an Xcode Workspace to be created or "automagically" managed. It can be installed via a [downloadable installer](https://github.com/Carthage/Carthage/releases) or with a simple `brew install carthage`.

Create a `Cartfile`, which is just a plain text file filled with lines like the ones below. Each of these tell **Carthage** about a library you’d like to use in your app.

``` ruby
github 'Alamofire/Alamofire'
github 'Hearst-DD/ObjectMapper'
github 'Haneke/HanekeSwift'
```

Then, simply run `carthage update`. At which point **Carthage** will go out and download and build all the libraries you asked for.

Note: Similar to **CocoaPods’** `pod install`, you’ll also need to run `carthage update` anytime you change or update your `Cartfile`.

Where things begin to feel different from **CocoaPods** is that the next step is to *manually drag and drop* the frameworks **Carthage** built when you ran `carthage update` into the **Linked Frameworks and Libraries** of your Xcode target’s General settings panel.

Finally, import the libraries in your code:

``` swift
import Alamofire
import ObjectMapper
import Haneke
```

More info about **Carthage** can be found at [git.io/carthage](http://git.io/carthage)
