我正在尝试使用命令 firebase init
初始化 Firebase 项目,但我收到消息 Error: Command requires authentication, please run firebase login
.
当我跑 firebase login
,进程挂起,不返回提示:
之前我安装了最新的稳定版 node.js 和 火力工具 (与 npm install -g firebase-tools
)。我使用的是 Windows 8.1 x64 机器。
的内容firebase-debug.log 文件 noes 不报告任何错误或警告:
[debug] ----------------------------------------------------------------------
[debug] Command: C:\Program Files (x86)\nodejs\node.exe C:\Users\ \AppData\Roaming\npm\node_modules\firebase-tools\bin\firebase login
[debug] Platform: win32
[debug] Node Version: v5.1.0
[debug] Time: Mon Nov 23 2015 13:49:06 GMT-0500 (Eastern Standard Time)
[debug] ----------------------------------------------------------------------
[debug]
如何调试登录命令?通常它应该打开一个浏览器窗口进行身份验证,但在我的情况下不会发生这种情况。
最佳答案
你得到答案了吗?
您需要输入“firebase login --interactive”,然后它会带您通过浏览器进入 Gmail 帐户进行登录,然后您可以执行“firebase init”命令。
关于firebase-tools - 无法使用 firebase-tools 初始化 firebase 项目,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33878563/