I have created the following function in my the file of my firebase cloud functions:
function whatsMyName(name) {
return "your name is " + name
}
When I run the following in the command line, then the function is deployed:
firebase deploy --only functions
But, this deploys all of my functions. I would like to only deploy the whatsMyName
function. Typically, if I have a function that is exported, like so:
exports.someExportedFunction = functions.https.onRequest((req, res) => {
// do some stuff
}
Then I can run the following to deploy the exported function:
firebase deploy --only functions:someExportedFunction
However, when I run the following, the non-exported function is not deployed:
firebase deploy --only functions:whatsMyName
Does anyone understand why this doesn't individually deploy my non-exported function, whatsMyName
, and how to deploy a non-exported function for Firebase Cloud Functions?