Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>XML Tools 4 SFNew to Visual Studio Code? Get it now.
XML Tools 4 SF

XML Tools 4 SF

Cristiano Biral Jorge

|
36 installs
| (0) | Free
xml tools for salesforce developers
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

X2SF README

Tools for analysis Salesforce metadata files after merging changes.

Features

1 - Find Duplicates

Find duplicate tags comparing tag name and text content

At this sample file, the tags <sorted> and <customValue> are duplicated

<?xml version="1.0" encoding="UTF-8"?>
<GlobalValueSet xmlns="http://soap.sforce.com/2006/04/metadata">
    <masterLabel>ExampleGlobalValueSet</masterLabel>
    <description>This is an example Global Value Set</description>
    <sorted>false</sorted> <!-- 1º <sorted> occur ::ok:: -->
    <sorted>false</sorted> <!-- 2º <sorted> occur ::duplicity!:: -->
    <customValue> <!-- 1º <customValue> occur ::ok:: -->
        <fullName>Value1</fullName>
        <default>false</default>
        <label>Value 1</label>
    </customValue>
    <customValue>
        <fullName>Value2</fullName>
        <default>false</default>
        <label>Value 2</label>
    </customValue>
    <customValue> <!-- 2º <customValue> occur ::duplicity!:: -->
        <fullName>Value1</fullName>
        <default>false</default>
        <label>Value 1</label>
    </customValue>
</GlobalValueSet>

A notification for each duplication are showed
and cursor are positioned at the first duplicity

image


2 - Remove Duplicates by Key Tag Path

Remove duplicate tags comparing key tag path input

At this sample file, the tag <customValue> are duplicated

<?xml version="1.0" encoding="UTF-8"?>
<GlobalValueSet xmlns="http://soap.sforce.com/2006/04/metadata">
    <masterLabel>ExampleGlobalValueSet</masterLabel>
    <description>This is an example Global Value Set</description>
    <sorted>false</sorted>
    <customValue> <!-- 1º <customValue> occur ::ok:: -->
        <fullName>Value1</fullName>
        <default>false</default>
        <label>Value 1</label>
    </customValue>
    <customValue>
        <fullName>Value2</fullName>
        <default>false</default>
        <label>Value 2</label>
    </customValue>
    <customValue> <!-- 2º <customValue> occur ::duplicity!:: -->
        <fullName>Value1</fullName>
        <default>false</default>
        <label>Value 1</label>
    </customValue>
</GlobalValueSet>

Input the key tag path to find duplicates

image

A notification for each duplication are showed

image

Only first occurrence stay in file

<?xml version="1.0" encoding="UTF-8"?>
<GlobalValueSet xmlns="http://soap.sforce.com/2006/04/metadata">
    <masterLabel>ExampleGlobalValueSet</masterLabel>
    <description>This is an example Global Value Set</description>
    <sorted>false</sorted>
    <customValue> <!-- 1º <customValue> occur ::ok:: -->
        <fullName>Value1</fullName>
        <default>false</default>
        <label>Value 1</label>
    </customValue>
    <customValue>
        <fullName>Value2</fullName>
        <default>false</default>
        <label>Value 2</label>
    </customValue>
</GlobalValueSet>

Release Notes

1.0.0

Add feature to find duplicates by tag path


0.0.1

Find Duplicates in the active xml file


  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft