From 4e7d1206192d561e758b183326cc27a85cebf2c6 Mon Sep 17 00:00:00 2001 From: Kamesh Tanneru <36271852+tkamesh@users.noreply.github.com> Date: Tue, 5 Apr 2022 17:00:00 +0530 Subject: [PATCH 1/2] feat: add is_static_export flag. --- Tasks/AzureStaticWebAppV0/index.ts | 2 ++ Tasks/AzureStaticWebAppV0/task.json | 10 +++++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/Tasks/AzureStaticWebAppV0/index.ts b/Tasks/AzureStaticWebAppV0/index.ts index 7de55daac152..649b74b0ca8d 100644 --- a/Tasks/AzureStaticWebAppV0/index.ts +++ b/Tasks/AzureStaticWebAppV0/index.ts @@ -83,6 +83,7 @@ async function createDockerEnvVarFile(envVarFilePath: string) { const skipAppBuild: boolean = tl.getBoolInput('skip_app_build', false); const skipApiBuild: boolean = tl.getBoolInput('skip_api_build', false); + const isStaticExport: boolean = tl.getBoolInput('is_static_export', false); const apiToken: string = process.env[apiTokenInputName] || tl.getInput(apiTokenInputName, false) || ""; const systemVerbose = getNullableBooleanFromString(process.env['SYSTEM_DEBUG']); @@ -106,6 +107,7 @@ async function createDockerEnvVarFile(envVarFilePath: string) { addSystemVariableToString("SKIP_APP_BUILD", skipAppBuild.toString()); addSystemVariableToString("SKIP_API_BUILD", skipApiBuild.toString()); + addSystemVariableToString("IS_STATIC_EXPORT", isStaticExport.toString()); addSystemVariableToString("VERBOSE", verbose.toString()); addInputStringToString("DEPLOYMENT_TOKEN", apiToken, apiTokenInputName); diff --git a/Tasks/AzureStaticWebAppV0/task.json b/Tasks/AzureStaticWebAppV0/task.json index 02b5bb2a7c0a..d877dc7f0aaa 100644 --- a/Tasks/AzureStaticWebAppV0/task.json +++ b/Tasks/AzureStaticWebAppV0/task.json @@ -14,7 +14,7 @@ "demands": [], "version": { "Major": "0", - "Minor": "202", + "Minor": "204", "Patch": "0" }, "preview": true, @@ -105,6 +105,14 @@ "required": false, "helpMarkDown": "Skips Oryx build for api folder" }, + { + "name": "is_static_export", + "type": "boolean", + "label": "Set static export", + "defaultValue": "", + "required": false, + "helpMarkDown": "Set this flag to true when your application is configured to export to static HTML, i.e. when if you're using `next export`." + }, { "name": "verbose", "type": "boolean", From 062e68d6105b38e2688efb6562fd6089ba3a8d4f Mon Sep 17 00:00:00 2001 From: Kamesh Tanneru <36271852+tkamesh@users.noreply.github.com> Date: Wed, 13 Apr 2022 16:56:21 +0530 Subject: [PATCH 2/2] update minor version. --- Tasks/AzureStaticWebAppV0/task.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tasks/AzureStaticWebAppV0/task.json b/Tasks/AzureStaticWebAppV0/task.json index d877dc7f0aaa..79a4a29543ef 100644 --- a/Tasks/AzureStaticWebAppV0/task.json +++ b/Tasks/AzureStaticWebAppV0/task.json @@ -14,7 +14,7 @@ "demands": [], "version": { "Major": "0", - "Minor": "204", + "Minor": "203", "Patch": "0" }, "preview": true,