Skip to content

Commit

Permalink
update.
Browse files Browse the repository at this point in the history
  • Loading branch information
imcarolwang committed Oct 21, 2024
1 parent db11dd1 commit 9c7c503
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
7 changes: 1 addition & 6 deletions src/dotnet-svcutil/lib/src/CommandProcessorOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -627,12 +627,7 @@ private async Task ProcessReferencesOptionAsync(CancellationToken cancellationTo
{
for (int idx = this.References.Count - 1; idx >= 0; idx--)
{
var selected = references.Where(x => string.Equals(this.References[idx].Name, x.Name, StringComparison.OrdinalIgnoreCase)).FirstOrDefault();
if (selected != null)
{
this.References[idx] = selected;
}
else
if (!references.Contains(this.References[idx]))
{
this.References.RemoveAt(idx);
}
Expand Down
4 changes: 3 additions & 1 deletion src/dotnet-svcutil/lib/src/Shared/Options/UpdateOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,9 @@ public void ResolveFullPathsFrom(DirectoryInfo optionsFileDirectory)
var reference = this.References[idx];
if (reference.DependencyType == ProjectDependencyType.Project || reference.DependencyType == ProjectDependencyType.Binary)
{
this.References[idx].FullPath = Path.Combine(optionsFileDirectory.FullName, reference.ReferenceIdentity);
string fullPath = Path.GetFullPath(Path.Combine(optionsFileDirectory.FullName, reference.ReferenceIdentity));
this.References[idx].FullPath = fullPath;
this.References[idx].ReferenceIdentity = fullPath;
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/dotnet-svcutil/lib/src/Shared/ProjectDependency.cs
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ private ProjectDependency(string filePath = "", string packageName = "", string

this.ReferenceIdentity = this.DependencyType == ProjectDependencyType.Package || this.DependencyType == ProjectDependencyType.Tool || !string.IsNullOrWhiteSpace(packageName) ?
string.Format(CultureInfo.InvariantCulture, "{0}, {{{1}, {2}}}", this.AssemblyName, this.Name, this.Version) :
this.FullPath;
filePath;

this.IsFramework = this.Name == NetCoreAppPackageID || this.Name == NetStandardLibraryPackageID;
}
Expand Down

0 comments on commit 9c7c503

Please sign in to comment.