将steam postgresql连接器添加到Package.swift
后出现构建错误 import PackageDescription
let package = Package(
name: "todo_vapor_swift",
dependencies: [
.Package(url: "https://github.com/vapor/vapor.git", majorVersion: 1, minor: 5),
.Package(url: "https://github.com/vapor/postgresql-provider", majorVersion: 1, minor: 0)
],
exclude: [
"Config",
"Database",
"Localization",
"Public",
"Resources",
]
)
答案 0 :(得分:11)
也许你用Postgress.app或其他方式安装了postgress。您需要使用brew安装来解决此错误。
运行以下内容:brew install postgres