【发布时间】:2018-06-29 00:14:02
【问题描述】:
在 Typescripts 中编写了我的第一个 firebase 函数后,我想部署该函数,但是这个错误突然出现在任何地方。当我输入命令firebase deploy
i deploying firestore, functions, hosting
Running command: npm --prefix $RESOURCE_DIR run lint
npm ERR! Windows_NT 10.0.17035
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program
Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "--prefix"
"$RESOURCE_DIR" "run" "lint"
npm ERR! node v6.11.5
npm ERR! npm v3.10.10
npm ERR! path F:\Projects\Angular
Projects\<project_derectory>\$RESOURCE_DIR\package.json
npm ERR! code ENOENT
npm ERR! errno -4058
npm ERR! syscall open
npm ERR! enoent ENOENT: no such file or directory, open 'F:\Projects\Angular
Projects\<project_derectory>\$RESOURCE_DIR\package.json'
npm ERR! enoent ENOENT: no such file or directory, open 'F:\Projects\Angular
Projects\<project_derectory>\$RESOURCE_DIR\package.json'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! F:\Projects\Angular Projects\<project_derectory>\npm-debug.log
Error: functions predeploy error: Command terminated with non-zero exit code4294963238
我已按照this medium blog tutorial的步骤操作
【问题讨论】:
-
那个博客很旧。如果你想用 TypeScript 编写云函数,你应该得到最新的 Firebase CLI,它原生支持 TS。 firebase.googleblog.com/2018/01/…
标签: angular typescript firebase webpack google-cloud-functions