Created
March 7, 2013 15:44
-
-
Save garyjohnson/5108949 to your computer and use it in GitHub Desktop.
Powershell script for comparing CS to VB file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Function Compare-VB($csFilePath) { | |
| $tempFile = [System.IO.Path]::GetTempPath() + [guid]::NewGuid() + ".vb" | |
| & 'C:\Program Files\InstantVB\InstantVB.exe' $csFilePath $tempFile | |
| WaitForFile($tempFile) | |
| & 'C:\Program Files (x86)\Beyond Compare 3\BCompare.exe' $csFilePath.Replace(".cs",".vb") $tempFile | |
| } | |
| Function WaitForFile($path) { | |
| while(!(Test-Path $path)) { | |
| Start-Sleep -s 1 | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment