|
|
@ -22,7 +22,7 @@ namespace Volo.Abp.Cli.ProjectBuilding.Building.Steps |
|
|
|
|
|
|
|
|
new ProjectReferenceReplacer.LocalProjectPathReferenceReplacer( |
|
|
new ProjectReferenceReplacer.LocalProjectPathReferenceReplacer( |
|
|
context.Files, |
|
|
context.Files, |
|
|
"MyCompanyName.MyProjectName", |
|
|
context.Module.Namespace, |
|
|
localAbpRepoPath |
|
|
localAbpRepoPath |
|
|
).Run(); |
|
|
).Run(); |
|
|
} |
|
|
} |
|
|
@ -65,14 +65,14 @@ namespace Volo.Abp.Cli.ProjectBuilding.Building.Steps |
|
|
private abstract class ProjectReferenceReplacer |
|
|
private abstract class ProjectReferenceReplacer |
|
|
{ |
|
|
{ |
|
|
private readonly List<FileEntry> _entries; |
|
|
private readonly List<FileEntry> _entries; |
|
|
private readonly string _companyAndProjectNamePlaceHolder; |
|
|
private readonly string _projectName; |
|
|
|
|
|
|
|
|
protected ProjectReferenceReplacer( |
|
|
protected ProjectReferenceReplacer( |
|
|
List<FileEntry> entries, |
|
|
List<FileEntry> entries, |
|
|
string companyAndProjectNamePlaceHolder) |
|
|
string projectName) |
|
|
{ |
|
|
{ |
|
|
_entries = entries; |
|
|
_entries = entries; |
|
|
_companyAndProjectNamePlaceHolder = companyAndProjectNamePlaceHolder; |
|
|
_projectName = projectName; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
public void Run() |
|
|
public void Run() |
|
|
@ -108,7 +108,7 @@ namespace Volo.Abp.Cli.ProjectBuilding.Building.Steps |
|
|
var oldNodeIncludeValue = oldNode.Attributes["Include"].Value; |
|
|
var oldNodeIncludeValue = oldNode.Attributes["Include"].Value; |
|
|
|
|
|
|
|
|
// ReSharper disable once PossibleNullReferenceException : Can not be null because nodes are selected with include attribute filter in previous method
|
|
|
// ReSharper disable once PossibleNullReferenceException : Can not be null because nodes are selected with include attribute filter in previous method
|
|
|
if (oldNodeIncludeValue.Contains($"{_companyAndProjectNamePlaceHolder}")) |
|
|
if (oldNodeIncludeValue.Contains($"{_projectName}")) |
|
|
{ |
|
|
{ |
|
|
continue; |
|
|
continue; |
|
|
} |
|
|
} |
|
|
@ -140,8 +140,8 @@ namespace Volo.Abp.Cli.ProjectBuilding.Building.Steps |
|
|
{ |
|
|
{ |
|
|
private readonly string _nugetPackageVersion; |
|
|
private readonly string _nugetPackageVersion; |
|
|
|
|
|
|
|
|
public NugetReferenceReplacer(List<FileEntry> entries, string companyAndProjectNamePlaceHolder, string nugetPackageVersion) |
|
|
public NugetReferenceReplacer(List<FileEntry> entries, string projectName, string nugetPackageVersion) |
|
|
: base(entries, companyAndProjectNamePlaceHolder) |
|
|
: base(entries, projectName) |
|
|
{ |
|
|
{ |
|
|
_nugetPackageVersion = nugetPackageVersion; |
|
|
_nugetPackageVersion = nugetPackageVersion; |
|
|
} |
|
|
} |
|
|
@ -177,8 +177,8 @@ namespace Volo.Abp.Cli.ProjectBuilding.Building.Steps |
|
|
{ |
|
|
{ |
|
|
private readonly string _gitHubLocalRepositoryPath; |
|
|
private readonly string _gitHubLocalRepositoryPath; |
|
|
|
|
|
|
|
|
public LocalProjectPathReferenceReplacer(List<FileEntry> entries, string companyAndProjectNamePlaceHolder, string gitHubLocalRepositoryPath) |
|
|
public LocalProjectPathReferenceReplacer(List<FileEntry> entries, string projectName, string gitHubLocalRepositoryPath) |
|
|
: base(entries, companyAndProjectNamePlaceHolder) |
|
|
: base(entries, projectName) |
|
|
{ |
|
|
{ |
|
|
_gitHubLocalRepositoryPath = gitHubLocalRepositoryPath; |
|
|
_gitHubLocalRepositoryPath = gitHubLocalRepositoryPath; |
|
|
} |
|
|
} |
|
|
|