Add Alamofire as a dependency through Swift 3 Package Manager

Swift 3 introduced a package manager with which I can add dependencies to my project.

For example, in my Package.swift, I can declare my dependency:

import PackageDescription

let package = Package(
    name: "my-project",
    dependencies: [
        .Package(url: "https://github.com/vapor/vapor.git", majorVersion: 0, minor: 16),
    ]
)

Now I need to add Alamofire to my project, how can I get it through Swift 3 package manager?

+4
source share
2 answers

You cannot use Alamofire yet because they have not released support for Swift 3.

, , GitHub readme, .

Luckly Vapor HTTP WebSockets. HTTP- : https://vapor.imtqy.com/documentation/http/client.html

+4

, Package.swift: .Package(url: "https://github.com/Alamofire/Alamofire.git", majorVersion: 4) :)

+2

Source: https://habr.com/ru/post/1653306/


All Articles