简体   繁体   中英

Vapor build failure

I am using Mac with Sierra OS (10.12.5). I Installed Vapor using home-brew. If I tried to run command 'vapor build' in terminal it shows following error.

No .build folder, fetch may take a while...
Fetching Dependencies [  •                      ]
Error: backgroundExecute(code: 1, error: "swift-package: error: unknown command: --enable-prefetching\n", output: "")

Please help me.

If you installed latest xcode and still getting error.

Goto: xcode -> Preferences -> Locations -> Command Line Tool

Change it to latest. Then check swift version. Then try vapor commands.

Looks like you are running Swift 3.0, where as the toolbox (and Vapor 2) required Swift 3.1.

Upgrade Swift to 3.1 (by upgrading Xcode usually) and it should work.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM