Files
firebase-tools/src/deploymentTool.js
Bryan Kendall 78f11b62ab Master Sync 10/25 (#970)
* Add emulator:run

* Cleanup

* Download emulators if needed

* Cleanup

* Remove unused dep

* Use CACHE_DIR

* Allow FIREBASE_EMULATORS_PATH to override the cache dir

* Format

* Simplify emulator remote storage

* Use fs-extra

* Hide emulator:run behind preview

* Cleanup

* Fix URL

* Remove old commands

* Point at real artifacts

* make emulators executable after downloading

* Allow --yes flag for emulator

* Prompt for emulator download

* Linter

* Emulator CLI per API Review (#318)

* Emulator CLI per API Review

* Cleanup

* Address comments

* Linter

* Add a useful error message for when the emulator cannot start because… (#329)

* Add a useful error message for when the emulator cannot start because Java is not installed

* linter

* action item

* Add start time to profiler dump (#323)

* Set emulator version for initial release (#336)

* Typescript (#338)

* The path structure layout seems like it changed (#341)

* The path structure layout seems like it changed

* Update src/auth.js

Co-Authored-By: ryanpbrewster <RyanPBrewster@gmail.com>

* Update functions init templates to v2.1.0 (#969) (#343)
2018-10-25 16:19:35 -07:00

25 lines
467 B
JavaScript

const BASE = "cli-firebase";
function _value() {
if (!process.env.FIREBASE_DEPLOY_AGENT) {
return BASE;
}
return [BASE, process.env.FIREBASE_DEPLOY_AGENT].join("--");
}
module.exports = {
base: BASE,
get value() {
return _value();
},
get labels() {
return {
"deployment-tool": _value(),
};
},
check: function(labels) {
return labels && labels["deployment-tool"] && labels["deployment-tool"].indexOf(BASE) === 0;
},
};