novi / mysql-swift

A type safe MySQL client for Swift
MIT License
163 stars 40 forks source link

how can add mysql-swift in package.swift v4.0 #59

Closed aliazadeh closed 7 years ago

aliazadeh commented 7 years ago

hi , I am new in swift with server side and now I don't how can add dependencies in package.swift this is my package.swift file let package = Package( name: "toDoPoj", dependencies: [

    // Dependencies declare other packages that this package depends on.
     .package(url: "https://github.com/IBM-Swift/Kitura.git", from: "1.7.9"),
     .package(url: "https://github.com/IBM-Swift/HeliumLogger.git", from: "1.7.1"),

     .package(url: "https://github.com/vapor/mysql-provider.git", from: "2.0.0"),

],
targets: [
    // Targets are the basic building blocks of a package. A target can define a module or a test suite.
    // Targets can depend on other targets in this package, and on products in packages which this package depends on.
    .target(
        name: "toDoPoj",
        dependencies: ["Kitura" , "HeliumLogger" ,  "mysql-provider" ]),
]

) what should I write after heliumLogger ! , I am confused that what should we write in target dependenciy ? :|

novi commented 7 years ago

I updated README. You could just add MySQL to target's dependency. And you would add .package(url: "https://github.com/novi/mysql-swift.git", .upToNextMinor(from: "0.8.0")) to the package dependency.