Erros de implantação do Firebase iniciando com código de saída diferente de zero (espaço no caminho do projeto)
Eu estava tendo problemas com o comando de implantação do firebase recentemente. Após o comando de implantação do firebase, todos os outros estavam sendo implantados, exceto o firebase (armazenamento, banco de dados etc.). Então, decidi reinstalar o firebase para corrigir essa situação, mas após a reinstalação, meu problema ficou maior. Agora, nenhum deles é implantado com o seguinte erro:
i deploying database, functions
Running command: npm --prefix $RESOURCE_DIR run lint
npm ERR! path C:\Users\faruk\Google Drive\Android\firebase\1\$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 'C:\Users\faruk\Google Drive\Android\firebase\1\$RESOURCE_DIR\package.json'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\faruk\AppData\Roaming\npm-cache\_logs\2018-01-24T18_21_34_878Z-debug.log
Error: functions predeploy error: Command terminated with non-zero exit code4294963238
Depois de um pouco de pesquisa, vi alguns tópicos sobre isso que conselhos para mudar
$RESOURCE_DIR to %RESOURCE_DIR%
em sistemas windows (eu estou usando o windows 10 btw). Então, eu editei meufirebase.json arquivo que está em um nível superior da minha pasta de funções. como isso. (Não sei se este é o arquivo correto que devo editar)
"database": {
"rules": "database.rules.json"
},
"functions": {
"predeploy": [
"npm --prefix %RESOURCE_DIR% run lint"
]
}
}
mas após essa edição, comecei a receber outra mensagem de erro como esta.
i deploying database, functions
Running command: npm --prefix %RESOURCE_DIR% run lint
Usage: npm <command>
where <command> is one of:
access, adduser, bin, bugs, c, cache, completion, config,
ddp, dedupe, deprecate, dist-tag, docs, doctor, edit,
explore, get, help, help-search, i, init, install,
install-test, it, link, list, ln, login, logout, ls,
outdated, owner, pack, ping, prefix, profile, prune,
publish, rb, rebuild, repo, restart, root, run, run-script,
s, se, search, set, shrinkwrap, star, stars, start, stop, t,
team, test, token, tst, un, uninstall, unpublish, unstar,
up, update, v, version, view, whoami
npm <command> -h quick help on <command>
npm -l display full usage info
npm help <term> search for help on <term>
npm help npm involved overview
Specify configs in the ini-formatted file:
C:\Users\faruk\.npmrc
or on the command line via: npm <command> --key value
Config info can be viewed via: npm help config
[email protected] C:\Program Files\nodejs\node_modules\npm
Error: functions predeploy error: Command terminated with non-zero exit code1
Qualquer conselho é apreciado. Desde já, obrigado.