Browse Source
Merge pull request #3060 from abpframework/maliming/cli-patch
Restore the sourceFile variable.
pull/3064/head
Yunus Emre Kalkan
7 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
5 additions and
4 deletions
-
framework/src/Volo.Abp.Cli.Core/Volo/Abp/Cli/ProjectModification/NugetPackageToLocalReferenceConverter.cs
|
|
|
@ -1,4 +1,4 @@ |
|
|
|
using System; |
|
|
|
using System; |
|
|
|
using System.Collections.Generic; |
|
|
|
using System.IO; |
|
|
|
using System.Linq; |
|
|
|
@ -52,6 +52,7 @@ namespace Volo.Abp.Cli.ProjectModification |
|
|
|
|
|
|
|
foreach (XmlNode oldNode in nodes) |
|
|
|
{ |
|
|
|
var tempSourceFile = sourceFile; |
|
|
|
var oldNodeIncludeValue = oldNode?.Attributes?["Include"]?.Value; |
|
|
|
|
|
|
|
var moduleName = nugetPackageList.FirstOrDefault(n => n.NugetPackage.Name == oldNodeIncludeValue)?.ModuleName; |
|
|
|
@ -67,11 +68,11 @@ namespace Volo.Abp.Cli.ProjectModification |
|
|
|
if (oldNodeIncludeValue.EndsWith(".test", StringComparison.InvariantCultureIgnoreCase) || |
|
|
|
oldNodeIncludeValue.EndsWith(".tests", StringComparison.InvariantCultureIgnoreCase)) |
|
|
|
{ |
|
|
|
sourceFile = "test"; |
|
|
|
tempSourceFile = "test"; |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
sourceFile = "src"; |
|
|
|
tempSourceFile = "src"; |
|
|
|
} |
|
|
|
} |
|
|
|
else |
|
|
|
@ -81,7 +82,7 @@ namespace Volo.Abp.Cli.ProjectModification |
|
|
|
} |
|
|
|
|
|
|
|
var referenceProjectPath = |
|
|
|
$"{localPathPrefix}{moduleName}\\{sourceFile}\\{oldNodeIncludeValue}\\{oldNodeIncludeValue}.csproj"; |
|
|
|
$"{localPathPrefix}{moduleName}\\{tempSourceFile}\\{oldNodeIncludeValue}\\{oldNodeIncludeValue}.csproj"; |
|
|
|
|
|
|
|
XmlNode newNode = GetNewReferenceNode(doc, referenceProjectPath); |
|
|
|
|
|
|
|
|