From 0819605c416e3739e39a9fd05e839b8823a9b4a5 Mon Sep 17 00:00:00 2001 From: Jon Edvald Date: Thu, 7 Feb 2019 16:56:25 -0800 Subject: [PATCH] fix(deploy): make watch parameter implicit when hot-reloading --- garden-service/src/commands/deploy.ts | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/garden-service/src/commands/deploy.ts b/garden-service/src/commands/deploy.ts index 86d08cc456..1ce3515374 100644 --- a/garden-service/src/commands/deploy.ts +++ b/garden-service/src/commands/deploy.ts @@ -23,7 +23,6 @@ import { processServices } from "../process" import { logHeader } from "../logger/util" import { HotReloadTask } from "../tasks/hot-reload" import { BaseTask } from "../tasks/base" -import { ParameterError } from "../exceptions" const deployArgs = { services: new StringsParameter({ @@ -90,12 +89,8 @@ export class DeployCommand extends Command { return { result: {} } } - const watch = opts.watch const hotReloadServiceNames = opts["hot-reload"] || [] - - if (hotReloadServiceNames.length > 0 && !watch) { - throw new ParameterError(`Must specify --watch flag when requesting hot-reloading`, { opts }) - } + const watch = opts.watch || hotReloadServiceNames.length > 0 // TODO: make this a task await garden.actions.prepareEnvironment({ log })