- 메모장에서 build.proj 파일을 만들어서 아래의 내용을 복사해서 붙여넣기 한후 저장
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<OutputPath>.\output</OutputPath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)' == 'Debug'">
<Optimize>false</Optimize>
<DebugSymbols>true</DebugSymbols>
<OutputPath>$(OutputPath)\Debug</OutputPath>
</PropertyGroup>
<PropertyGroup>
<OutputPath>.\output</OutputPath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)' == 'Debug'">
<Optimize>false</Optimize>
<DebugSymbols>true</DebugSymbols>
<OutputPath>$(OutputPath)\Debug</OutputPath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)'=='Release'">
<Optimize>true</Optimize>
<DebugSymbols>false</DebugSymbols>
<OutputPath>$(OutputPath)\Release</OutputPath>
</PropertyGroup>
<Target Name="Build">
<MSBuild Projects="BuildTest.sln" Targets="rebuild"> </MSBuild>
<Exec Command="revc.exe" />
<!--<MakeDir Directories= "$(OutputPath)" />-->
<!--<Copy SourceFiles="build.proj" DestinationFiles="$(OutputPath)\build.txt" />-->
</Target>
</Project>
<Optimize>true</Optimize>
<DebugSymbols>false</DebugSymbols>
<OutputPath>$(OutputPath)\Release</OutputPath>
</PropertyGroup>
<Target Name="Build">
<MSBuild Projects="BuildTest.sln" Targets="rebuild"> </MSBuild>
<Exec Command="revc.exe" />
<!--<MakeDir Directories= "$(OutputPath)" />-->
<!--<Copy SourceFiles="build.proj" DestinationFiles="$(OutputPath)\build.txt" />-->
</Target>
</Project>
사용방법
- MSBuild MyApp.sln /t:Rebuild /p:Configuration=Release
- MSBuild MyApp.vcproj /t:Rebuild /p:Configuration=Debug
728x90
반응형
'C#' 카테고리의 다른 글
프로시저 Print 메세지 (0) | 2015.12.02 |
---|---|
ASCII 파일 읽기 / 쓰기 (0) | 2015.09.02 |
C# 반올림, 올림, 버림 사용하기 (0) | 2015.07.24 |
C#에서 PDF출력하기 (0) | 2015.07.24 |
운영체제에 등록되지 않은 폰트 사용하기 (0) | 2015.07.23 |