Cloud Functions deploy error during lint on Windows: “enoent ENOENT: no such file or directory”

后端 未结 9 2480
轻奢々
轻奢々 2020-11-27 07:07

Following the firebase function getting started guide and getting a seemingly simple error once trying to deploy with:

firebase deploy --only functions

i  d         


        
9条回答
  •  失恋的感觉
    2020-11-27 07:58

    This is a known problem with the Firebase CLI 3.17.0 through at least 3.17.3, but only on Windows. You can fix this on your machine by editing firebase.json at the root of your project and replacing $RESOURCE_DIR with %RESOURCE_DIR% in the npm commands you see there. The former is the unix syntax way to use an environment variable, whereas the latter is the Windows command shell syntax. Since you're using Windows, you need to use the Windows syntax.

    The team is looking into ways to prevent having to make changes to the config files you use, as it's not really convenient for teams that works across platform to keep changing the same file back and forth.

    EDIT: This issue should be fixed with projects created with CLI version 3.17.5.

提交回复
热议问题