title: Custom Build Files changes do not trigger project rebuild in VS 2017
body: <p>In my C++ VS project I added a custom target to compile shader files and set it as a initial target. This is the project xml</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;Project InitialTargets="CompileShaders" DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"&gt;
   
   ..... Normal Default VS C++ content here ......
  
   &lt;ItemGroup&gt;
      &lt;GLSLShader Include="SPIR-V\canvas2D.vert" /&gt;
      &lt;GLSLShader Include="SPIR-V\canvas2D.frag" /&gt;
  &lt;/ItemGroup&gt;
   
    
    
    &lt;Target Name="CompileShaders" Inputs="@(GLSLShader)" Outputs="SPIR-V\shaders_bytecode.h" &gt;
      &lt;PropertyGroup&gt;
        &lt;OriginalFileName&gt;%(GLSLShader.Filename)%(GLSLShader.Extension)&lt;/OriginalFileName&gt;
      &lt;/PropertyGroup&gt;
      &lt;Message Text="Start Compiling GSLANG @(GLSLShader) " /&gt;
      &lt;Message Condition="'$(VULKAN_SDK)'==''" Text="Error, cant find environment variable VULKAN_SDK, Make sure that the  Lunar  Vulkan SDK is installed" /&gt;
      &lt;Message Condition="'$(VULKAN_SDK)'!=''" Text="$(VULKAN_SDK)\Bin\glslangValidator.exe %(GLSLShader.Filename)%(GLSLShader.Extension) -V --vn $([System.String]::Copy('%(GLSLShader.Filename)%(GLSLShader.Extension)').Replace('.','_')) -o %(GLSLShader.Filename)%(GLSLShader.Extension).h" /&gt;
      &lt;Exec Condition="'$(VULKAN_SDK)'!=''" Command="$(VULKAN_SDK)\Bin\glslangValidator.exe %(GLSLShader.Filename)%(GLSLShader.Extension) -V --vn $([System.String]::Copy('%(GLSLShader.Filename)%(GLSLShader.Extension)').Replace('.','_')) -o %(GLSLShader.Filename)%(GLSLShader.Extension).h" WorkingDirectory="$(ProjectDir)\SPIR-V" /&gt;
      &lt;Exec Condition="'$(VULKAN_SDK)'!=''" Command="del shaders_bytecode.h" WorkingDirectory="$(ProjectDir)\SPIR-V" /&gt;
      &lt;Exec Condition="'$(VULKAN_SDK)'!=''" Command="type %(GLSLShader.Filename)%(GLSLShader.Extension).h &amp;gt;&amp;gt; shaders_bytecode.h" WorkingDirectory="$(ProjectDir)\SPIR-V" /&gt;
      &lt;Exec Condition="'$(VULKAN_SDK)'!=''" Command="del %(GLSLShader.Filename)%(GLSLShader.Extension).h" WorkingDirectory="$(ProjectDir)\SPIR-V" /&gt;
      
    &lt;/Target&gt;
  &lt;/Project&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>if I change any .cpp .h file and build the solution, the shaders are compiled together with the rest of the project, but if I change only the shader files (i.e SPIR-V\canvas2D.vert) the project is not built. VS says that the project is up to date. </p>
  
  <p>Now the strange thing, If I run the project using msbuild on the terminal ouside VS, the shader files changes are enough to trigger the rebuild. Go figure....!!!</p>
  
  <p>It looks like something related to how VS build projects. It is outside the msbuild.</p>