Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Delete all firebase functions

I have a firebase project with multiple functions deployed. Is it possible to remove all the functions in a single go through the CLI?

I tried the command firebase functions:delete --region us-central1 and the error output was Error: Must supply at least function or group name.

As of right now, I deleted all of them specifying each of their names as such: firebase functions:delete function1 function2 ...functionN but this is very cumbersome.

The version of firebase-tools installed is v4.0.0

like image 903
Manish Shrestha Avatar asked Jul 27 '18 13:07

Manish Shrestha


3 Answers

Just comment (or delete) all the functions in your index.js file and redeploy it through the CLI.

like image 91
Renaud Tarnec Avatar answered Oct 21 '22 16:10

Renaud Tarnec


Sign in to your Google Cloud Console at https://console.cloud.google.com, select your project, then from the list on the left pick Cloud Functions. When you get the list of functions, click the check box on the header line to select all, then the Delete button in the tool bar.

Update for comment:

I don't know what the product strategy for Firebase Console is with regard to Cloud Functions. My guess is that it is intended to provide a simplified, more convenient interface for managing Firebase related cloud functions. The Google Cloud Console provides a richer set of capabilities for managing functions and viewing logs. You could submit a feature request to Firebase to get those capabilities added to the Firebase console. Some details on the Firebase/Google Cloud relationship are provided at these links:

https://stackoverflow.com/a/42859932/4815718

https://cloud.google.com/functions/docs/concepts/functions-and-firebase

like image 21
Bob Snyder Avatar answered Oct 21 '22 18:10

Bob Snyder


Adding other deletion options. For more information, checkout Firebase official documentation.

enter image description here

like image 44
genericUser Avatar answered Oct 21 '22 18:10

genericUser