Console applications provide a quick and easy way (and also a little bit dirty) to test or fix parts of your application. It enables you to focus on the business logic rather than the GUI. Sometimes the output to the window is quite large – larger than the console window can show. In those cases you want to be able to persist the output to text files. In this post, I’ll show you how to do this.
Here’s a very simple utility that recursively finds uppercase file extensions and makes those who are lowercase. For once, it’s not written in C# but in good old DOS. If you paste this code in a CMD file, you’ll have a working program. If you execute this cmd, it will take the current folder as the root and it will process all files and subfolders.
Nowadays you would use PowerShell but this is a way to provide a quick fix to your users.