Skip to content

Extension Settings

Josh Johnson edited this page Jan 29, 2016 · 3 revisions

Extension Settings Reference

  • xmlTools.persistXPathQuery: When true, the extension will remember the last XPath query used for a given document. If a folder is not opened in VS Code, the last XPath used since the extension was last activated will be used.

  • xmlTools.removeCommentsOnMinify: When true, XML comments will be stripped when using the XML Tools: Minify XML command.

  • xmlTools.splitXmlnsOnFormat: When true, XML namespace declarations will be placed on new lines when using the Format Code command.

  • xmlTools.xqueryExecutionEngine: The full path to the executable that should be used to execute XQuery scripts. This extension is tested on Windows with the AltovaXML 2008 engine.

  • xmlTools.xqueryExecutionArguments: An array of strings to use as command line arguments for the XQuery execution engine. There are special variables that may be used in these strings:

    • $(script): The full path to the XQuery script being executed.
    • $(input): The full path to the input XML file.
    • $(project): The full path to the current workspace/project folder.
  • xmlTools.ignoreDefaultNamespace: When true, the default XML namespace will be ignored when evaluating XPaths.

Default Extension Settings

{
    // -------- XML Tools Configuration --------

    "xmlTools.persistXPathQuery": true,
    "xmlTools.removeCommentsOnMinify": false,
    "xmlTools.splitXmlnsOnFormat": true,
    "xmlTools.xqueryExecutionEngine": "",
    "xmlTools.xqueryExecutionArguments": [
        "-xquery",
        "$(script)",
        "-in",
        "$(input)",
        "-out",
        "$(input).output.xml"
    ],
    "xmlTools.ignoreDefaultNamespace": true
}