Skip to content

Problems with Formatting Azure DevOps Yaml File with template and parameters #205

@pri-kise

Description

@pri-kise

Hi I want to use the extension with Azure DevOps Pipelines and want to use templates.

This is the result after formatting:

name: $(Build.BuildId)

variables:
  - group: Custom Settings

trigger: none

stages:
  - parameters:
      firstparamter: XXX
      secondparameter: YYY
    template: templates\CI.yml

This is the expected result:
I'd like to have the template line before the parameters line.

name: $(Build.BuildId)

variables:
  - group: 'Custom Settings'

trigger: none

stages:
  - template: templates\CI.yml
    parameters:
      firstparamter: 'XXX'
      secondparameter: 'YYY'

my settings for the extension:

{
    "vscode-yaml-sort.customSortKeywords_2": [
        "name",
        "variables",
        "trigger",
        "resources"
    ],
    "vscode-yaml-sort.emptyLinesUntilLevel": 1,
    "vscode-yaml-sort.useLeadingDashes": false
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions