美文网首页
git pull 后的VS项目 没有了虚拟目录

git pull 后的VS项目 没有了虚拟目录

作者: 古典小说 | 来源:发表于2019-07-17 10:53 被阅读0次

在源项目中 建立了许多虚拟目录,用以分类管理

在PULL后,发现,PULL的项目,没有了虚拟目录

对比发现:

原项目中有 .vcxproj.user 是用户的一些相关配置

PULL项目中 没有

原因:

1 ,vcxproj就是工程的配置文件,各种库,编译器设置,警告设置

            Debug      Win32              Release      Win32            {F8A53C18-A16D-47FF-9BDE-72AA9F7123A7}    Win32Proj    nls_demo    xnw-live 

2,vcxproj.filters 用于项目下文件的虚拟目录  ,筛选器 就是工程下的虚拟文件夹 便于归类文件 浏览试图 提高开发效率

<?xml version="1.0" encoding="utf-8"?>

<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

  <ItemGroup>

    <ClCompile Include="..\common\httprpc.cxx" />

    <ClCompile Include="gui\about\about_form.cpp" />

    <ClCompile Include="gui\helper\camera_select.cpp" />

    <ClCompile Include="gui\helper\capture_msg.cpp" />

    <ClCompile Include="gui\helper\capture_wnd.cpp" />

    <ClCompile Include="gui\helper\draw_unit.cpp" />

    <ClCompile Include="gui\helper\ui_capture_edit.cpp" />

    <ClCompile Include="gui\helper\window_select.cpp" />

    <ClCompile Include="gui\toast\toast.cpp" />

    <ClCompile Include="gui\tray_icon\tray_icon.cpp" />

    <ClCompile Include="main.cpp" />

    <ClCompile Include="module\nim_player_cpp_sdk\nim_player_cpp.cpp" />

    <ClCompile Include="module\thread\misc_thread.cpp" />

    <ClCompile Include="mylavaagnt.cpp" />

    <ClCompile Include="stdafx.cpp" />

    <ClCompile Include="WndX.cpp" />

    <ClCompile Include="xnwpush.cpp" />

    <ClCompile Include="gui\courselist\courselist_form.cpp">

      <Filter>courselist</Filter>

    </ClCompile>

3,vcxproj.user 是用户的一些相关配置

<?xml version="1.0" encoding="utf-8"?>

<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">

    <LocalDebuggerWorkingDirectory>..\bin</LocalDebuggerWorkingDirectory>

    <DebuggerFlavor>WindowsLocalDebugger</DebuggerFlavor>

  </PropertyGroup>

  <PropertyGroup>

    <ShowAllFiles>true</ShowAllFiles>

  </PropertyGroup>

  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">

    <LocalDebuggerWorkingDirectory>$(ProjectDir)..\bin</LocalDebuggerWorkingDirectory>

    <DebuggerFlavor>WindowsLocalDebugger</DebuggerFlavor>

  </PropertyGroup>

</Project>

值得注意的是  只有vcxproj.filters文件可能还是不能完成虚拟目录的显示,必须和vcxproj.user 搭配联合,才能显示出用于管理的虚拟目录

解决方法

在.gitignore中,将   *.user 去除,这样git 的时候就不会忽略各种用户配置了

然后 git status 

将 忽略掉的.user文件添加进去

再次PULL的时候,就会发现,新PULL的VS项目中 有虚拟目录了

相关文章

网友评论

      本文标题:git pull 后的VS项目 没有了虚拟目录

      本文链接:https://www.haomeiwen.com/subject/ixtqlctx.html