Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
320 views
in Technique[技术] by (71.8m points)

azure-functions-core-tools on Mac OS

I've used azure-functions-core-tools NPM package on a Mac using npm 5 and node 8, however I've got warnings, so I've updated node to v8.11.1 and npm to 5.6.0. After doing this I've installed brew reinstall azure-functions-core-tools and .NET Core SDK 2.1.105 for good measure.

However running npm i -g [email protected] or npm i -g azure-functions-core-tools results in

npm ERR! code EBADPLATFORM
npm ERR! notsup Unsupported platform for [email protected]: wanted {"os":"win32","arch":"any"} (current: {"os":"darwin","arch":"x64"})
npm ERR! notsup Valid OS:    win32
npm ERR! notsup Valid Arch:  any
npm ERR! notsup Actual OS:   darwin
npm ERR! notsup Actual Arch: x64

Does anyone else has this issue? Mac OS 10.12.6

I have same situation on two macs

EDIT: I even found previous install of azure-functions-core-tools in a terminal window enter image description here

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

For Mac OS, you should use npm i -g azure-functions-core-tools@core to install Azure function core tools 2.x, which can be cross-platform. azure-functions-core-tools is 1.x and can only run on Windows.

Update

npm i -g azure-functions-core-tools now is also used to install 2.x core tools, azure-functions-core-tools@1 is 1.x. See docs for latest command.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...