一處開發,多處同步編輯使用,而且發佈時各個項目都可獨立
.csproj
具體實現爲:編輯 .csproj
文件,在<ItemGroup>
中添加新的 <Content />
或 <Compile />
節點:
Include
: 屬性值爲項目文件的相對引用路徑
Link
: 節點中放置要引用到當前項目中的位置html
<ItemGroup> <Content Include="Views\_EmailOfficeCancelledEmail.cshtml"/> </ItemGroup>
<ItemGroup> <Content Include="..\MvcDemo\MvcWeb\Views\_EmailOfficeCancelledEmail.cshtml"> <Link>Views\_EmailOfficeCancelledEmail.cshtml</Link> </Content> </ItemGroup>
<ItemGroup> <Compile Include="Controllers\CommonController.cs"/> </ItemGroup>
<ItemGroup> <Compile Include="..\..\MvcDemo\MvcWeb\Controllers\CommonController.cs"> <Link>Controllers\HomeController.cs</Link> </Compile> </ItemGroup>
Visual Studio
軟件可視化操做