diff --git a/src/Microsoft.VisualStudio.ProjectSystem.Managed.VS/ProjectSystem/VS/UpToDate/BuildUpToDateCheck.FileSystemOperationAggregator.cs b/src/Microsoft.VisualStudio.ProjectSystem.Managed.VS/ProjectSystem/VS/UpToDate/BuildUpToDateCheck.FileSystemOperationAggregator.cs index e90ad7068f7..736e82a771c 100644 --- a/src/Microsoft.VisualStudio.ProjectSystem.Managed.VS/ProjectSystem/VS/UpToDate/BuildUpToDateCheck.FileSystemOperationAggregator.cs +++ b/src/Microsoft.VisualStudio.ProjectSystem.Managed.VS/ProjectSystem/VS/UpToDate/BuildUpToDateCheck.FileSystemOperationAggregator.cs @@ -174,8 +174,12 @@ public void AddCopy(string source, string destination) // TODO add retry logic in case of failed copies? MSBuild does this with CopyRetryCount and CopyRetryDelayMilliseconds - // Copy the file - _fileSystem.CopyFile(source, destination, overwrite: true, clearReadOnly: true); + FileInfo destinationFileInfo = new(destination); + if (!destinationFileInfo.Attributes.HasFlag(FileAttributes.ReparsePoint)) + { + // Copy the file + _fileSystem.CopyFile(source, destination, overwrite: true, clearReadOnly: true); + } copyCount++; }