Skip to content

Commit 0d36070

Browse files
author
wju
committed
fix extra version line in encodedTask created by file
1 parent 919923c commit 0d36070

File tree

4 files changed

+948
-282
lines changed

4 files changed

+948
-282
lines changed

src/azure-cli/azure/cli/command_modules/acr/_utils.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,8 +248,9 @@ def get_yaml_template(cmd_value, timeout, file):
248248
:param str timeout: The timeout for each step
249249
:param str file: The task definition
250250
"""
251-
yaml_template = "version: v1.1.0\n"
251+
yaml_template = ""
252252
if cmd_value:
253+
yaml_template += "version: v1.1.0\n"
253254
yaml_template += "steps: \n - cmd: {0}\n disableWorkingDirectoryOverride: true\n".format(cmd_value)
254255
if timeout:
255256
yaml_template += " timeout: {0}\n".format(timeout)

0 commit comments

Comments
 (0)