Visual Studio 2010 Add-In for sorting language XML files
As EPiServer sites grow, their language files usually grows rapidly as well. It’s not uncommon to have several hundred lines of language keys split into different files.
Maintaining such a site and making sure all language keys are translated in all languages can be a pain. I think there are a few Admin plugins for addressing these problems as well.
In our team we have a common practise to always have one language file per language, and to have them alphabetically sorted. That way, you can easily navigate through them, and by just comparing the line numbers you see if there are differences. No Admin plugins needed.
Problem is, to continuously sorting your keys in alphabetical order, can also be a pain :)
I put together a simple VS 2010 add-in, which installs to the right-click menu in Visual Studio.
Once clicked, the XML will sort on element name, like so:
The attached zip contains two files.
Put them in your /Documents/Visual Studio 2010/Addins folder
Visual Studio will pick up the addin:
Take it for a spin! Of course this add-in should work on any XML, even if it would be kind of pointless to sort your Web.config :)
Feel free to email me or twitter at @thomas_krantz
I’ll put the source code online somewhere if somebody is interested.Here’s the file: