标题几乎说明了一切。对于我的一个网站,我有一台运行批处理文件的服务器计算机,该批处理文件在为用户执行操作后更新数据库。完成此操作后,它将删除用户对数据库的请求。如何自动执行删除数据库中的内容的过程?如何跳过y/n确认(我知道对于某些命令,您可以使用/q或/s,但我似乎找不到用于Firebase命令的/q版本)?请分批回答。
发布于 2017-08-10 09:43:36
使用-y或--confirm。在CLI帮助文本中:
$ firebase database:remove --help
Usage: database:remove [options] <path>
remove data from your Firebase at the specified path
Options:
-h, --help output usage information
-y, --confirm pass this option to bypass confirmation prompt发布于 2021-10-26 09:26:59
如果有人需要对firebase函数执行相同的操作:删除,只需使用如下所述的--force选项:
firebase functions:delete --help
Usage: firebase functions:delete [options] [filters...]
delete one or more Cloud Functions by name or group name.
Options:
--region <region> Specify region of the function to be deleted. If omitted, functions from all regions whose names match the filters will be deleted.
-f, --force No confirmation. Otherwise, a confirmation prompt will appear.
-h, --help output usage information发布于 2017-08-10 03:15:48
找到了解决方案。最后,我进入PC上的firebase-update.js脚本,注释掉了提示符。
https://stackoverflow.com/questions/45597090
复制相似问题