set BUILD_PATH=C:\Windows\Microsoft.NET\Framework64\v4.0.30319
"%IDE_PATH%\devenv" /build Release ..\Windows\FooEditEngine.sln
+if errorlevel 1 goto error
"%IDE_PATH%\devenv" /build Release ..\WPF\FooEditEngine.sln
+if errorlevel 1 goto error
"%IDE_PATH%\devenv" /build Release ..\Metro\Test.sln
+if errorlevel 1 goto error
"%BUILD_PATH%\MSBuild.exe" /p:Configuration=Release ..\Help\fooeditengine_api.shfbproj
+if errorlevel 1 goto error
md dist
copy ..\Help\Help\Documentation.chm dist
md dist\metro\FooEditEngine.Metro\Themes
copy ..\Metro\FooEditEngnine\bin\Release\Themes\*.xaml dist\metro\FooEditEngine.Metro\Themes
+goto end
+
+:error
+pause
+
+:end
endlocal