Author: brett
Date: Fri Jan 13 17:08:54 2012
New Revision: 1231188
URL: http://svn.apache.org/viewvc?rev=1231188&view=rev
Log:
Allow project importer to choose from available configurations for the Azure
and ASP.NET plugins, but by default don't add any configuration
Modified:
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/ASPNetPomConverter.cs
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/AzurePomConverter.cs
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Digest/Model/ProjectDigest.cs
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/NPandayImporter.cs
incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.Designer.cs
incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.cs
Modified:
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/ASPNetPomConverter.cs
URL:
http://svn.apache.org/viewvc/incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/ASPNetPomConverter.cs?rev=1231188&r1=1231187&r2=1231188&view=diff
==============================================================================
---
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/ASPNetPomConverter.cs
(original)
+++
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/ASPNetPomConverter.cs
Fri Jan 13 17:08:54 2012
@@ -45,8 +45,15 @@ namespace NPanday.ProjectImporter.Conver
Plugin aspnetPlugin = AddPlugin("org.apache.npanday.plugins",
"aspnet-maven-plugin", null, false);
AddPluginExecution(aspnetPlugin, "prepare-package",
goals.ToArray(), null);
- // TODO: until XDT works, just use Web.config itself
- AddPluginConfiguration(aspnetPlugin, "webConfig", "Web.config");
+ if (!string.IsNullOrEmpty(projectDigest.WebConfig))
+ {
+ AddPluginConfiguration(aspnetPlugin, "webConfig", "Web." +
projectDigest.WebConfig + ".config");
+ }
+ else
+ {
+ // TODO: until XDT works, just use Web.config itself
+ AddPluginConfiguration(aspnetPlugin, "webConfig",
"Web.config");
+ }
Plugin msdeployPlugin = AddPlugin("org.apache.npanday.plugins",
"msdeploy-maven-plugin", null, false);
AddPluginExecution(msdeployPlugin, "create-msdeploy-package", new
string[] { "create-package" }, null);
Modified:
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/AzurePomConverter.cs
URL:
http://svn.apache.org/viewvc/incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/AzurePomConverter.cs?rev=1231188&r1=1231187&r2=1231188&view=diff
==============================================================================
---
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/AzurePomConverter.cs
(original)
+++
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Converter/Algorithms/AzurePomConverter.cs
Fri Jan 13 17:08:54 2012
@@ -88,6 +88,11 @@ namespace NPanday.ProjectImporter.Conver
AddPluginConfiguration(plugin, "frameworkVersion", "4.0");
}
+ if (!string.IsNullOrEmpty(projectDigest.CloudConfig))
+ {
+ AddPluginConfiguration(plugin, "serviceConfigurationFile",
projectDigest.CloudConfig);
+ }
+
if (writePom)
{
PomHelperUtility.WriteModelToPom(new
FileInfo(Path.Combine(projectDigest.FullDirectoryName, "pom.xml")), Model);
Modified:
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Digest/Model/ProjectDigest.cs
URL:
http://svn.apache.org/viewvc/incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Digest/Model/ProjectDigest.cs?rev=1231188&r1=1231187&r2=1231188&view=diff
==============================================================================
---
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Digest/Model/ProjectDigest.cs
(original)
+++
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/Digest/Model/ProjectDigest.cs
Fri Jan 13 17:08:54 2012
@@ -547,12 +547,25 @@ namespace NPanday.ProjectImporter.Digest
set { existingPom = value; }
}
-
-
private bool useMsDeploy;
- public bool UseMsDeploy {
+ public bool UseMsDeploy
+ {
get { return useMsDeploy; }
set { useMsDeploy = value; }
}
+
+ private string webConfig;
+ public string WebConfig
+ {
+ get { return webConfig; }
+ set { webConfig = value; }
+ }
+
+ private string cloudConfig;
+ public string CloudConfig
+ {
+ get { return cloudConfig; }
+ set { cloudConfig = value; }
+ }
}
}
Modified:
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/NPandayImporter.cs
URL:
http://svn.apache.org/viewvc/incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/NPandayImporter.cs?rev=1231188&r1=1231187&r2=1231188&view=diff
==============================================================================
---
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/NPandayImporter.cs
(original)
+++
incubator/npanday/trunk/dotnet/assemblies/NPanday.ProjectImporter/Engine/src/main/csharp/NPandayImporter.cs
Fri Jan 13 17:08:54 2012
@@ -118,8 +118,13 @@ namespace NPanday.ProjectImporter
/// <returns>An array of generated pom.xml filenames</returns>
public static string[] ImportProject(string solutionFile, string
groupId, string artifactId, string version, string scmTag, bool verifyTests,
bool useMsDeploy, ref string warningMsg)
{
- VerifyProjectToImport method = verifyTests ?
VerifyUnitTestsToUser.VerifyTests : (VerifyProjectToImport) null;
- return ImportProject(solutionFile, groupId, artifactId, version,
scmTag, method, useMsDeploy, ref warningMsg);
+ return ImportProject(solutionFile, groupId, artifactId, version,
scmTag, verifyTests, useMsDeploy, null, null, ref warningMsg);
+ }
+
+ public static string[] ImportProject(string solutionFile, string
groupId, string artifactId, string version, string scmTag, bool verifyTests,
bool useMsDeploy, string webConfig, string cloudConfig, ref string warningMsg)
+ {
+ VerifyProjectToImport method = verifyTests ?
VerifyUnitTestsToUser.VerifyTests : (VerifyProjectToImport)null;
+ return ImportProject(solutionFile, groupId, artifactId, version,
scmTag, method, useMsDeploy, webConfig, cloudConfig, ref warningMsg);
}
/// <summary>
@@ -164,7 +169,7 @@ namespace NPanday.ProjectImporter
/// <returns>An array of generated pom.xml filenames</returns>
public static string[] ImportProject(string solutionFile, string
groupId, string artifactId, string version, string scmTag,
VerifyProjectToImport verifyProjectToImport, ref string warningMsg)
{
- return ImportProject(solutionFile, groupId, artifactId, version,
scmTag, verifyProjectToImport, false, ref warningMsg);
+ return ImportProject(solutionFile, groupId, artifactId, version,
scmTag, verifyProjectToImport, false, null, null, ref warningMsg);
}
/// <summary>
@@ -179,7 +184,7 @@ namespace NPanday.ProjectImporter
/// <param name="verifyProjectToImport">A delegate That will Accept a
method for verifying Projects To Import</param>
/// <param name="scmTag">adds scm tags to parent pom.xml if not
string.empty or null</param>
/// <returns>An array of generated pom.xml filenames</returns>
- public static string[] ImportProject(string solutionFile, string
groupId, string artifactId, string version, string scmTag,
VerifyProjectToImport verifyProjectToImport, bool useMsDeploy, ref string
warningMsg)
+ public static string[] ImportProject(string solutionFile, string
groupId, string artifactId, string version, string scmTag,
VerifyProjectToImport verifyProjectToImport, bool useMsDeploy, string
webConfig, string cloudConfig, ref string warningMsg)
{
string[] result = null;
@@ -207,6 +212,8 @@ namespace NPanday.ProjectImporter
{
// set the project flag so that converters can look at it
later
pDigest.UseMsDeploy = useMsDeploy;
+ pDigest.CloudConfig = cloudConfig;
+ pDigest.WebConfig = webConfig;
filteredPrjDigests.Add(pDigest);
}
else
Modified:
incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.Designer.cs
URL:
http://svn.apache.org/viewvc/incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.Designer.cs?rev=1231188&r1=1231187&r2=1231188&view=diff
==============================================================================
---
incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.Designer.cs
(original)
+++
incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.Designer.cs
Fri Jan 13 17:08:54 2012
@@ -60,11 +60,15 @@ namespace NPanday.VisualStudio.Addin
this.label2 = new System.Windows.Forms.Label();
this.txtVersion = new System.Windows.Forms.TextBox();
this.useMsDeployCheckBox = new System.Windows.Forms.CheckBox();
+ this.label3 = new System.Windows.Forms.Label();
+ this.label4 = new System.Windows.Forms.Label();
+ this.webConfigComboBox = new System.Windows.Forms.ComboBox();
+ this.cloudConfigComboBox = new System.Windows.Forms.ComboBox();
this.SuspendLayout();
//
// btnBrowse
//
- this.btnBrowse.Location = new System.Drawing.Point(434, 37);
+ this.btnBrowse.Location = new System.Drawing.Point(435, 12);
this.btnBrowse.Margin = new System.Windows.Forms.Padding(2);
this.btnBrowse.Name = "btnBrowse";
this.btnBrowse.Size = new System.Drawing.Size(80, 23);
@@ -76,7 +80,7 @@ namespace NPanday.VisualStudio.Addin
// lblBrowseDotNetSolutionFile
//
this.lblBrowseDotNetSolutionFile.AutoSize = true;
- this.lblBrowseDotNetSolutionFile.Location = new
System.Drawing.Point(8, 43);
+ this.lblBrowseDotNetSolutionFile.Location = new
System.Drawing.Point(9, 17);
this.lblBrowseDotNetSolutionFile.Margin = new
System.Windows.Forms.Padding(2, 0, 2, 0);
this.lblBrowseDotNetSolutionFile.Name =
"lblBrowseDotNetSolutionFile";
this.lblBrowseDotNetSolutionFile.Size = new
System.Drawing.Size(67, 13);
@@ -85,7 +89,7 @@ namespace NPanday.VisualStudio.Addin
//
// txtBrowseDotNetSolutionFile
//
- this.txtBrowseDotNetSolutionFile.Location = new
System.Drawing.Point(118, 40);
+ this.txtBrowseDotNetSolutionFile.Location = new
System.Drawing.Point(119, 14);
this.txtBrowseDotNetSolutionFile.Margin = new
System.Windows.Forms.Padding(2);
this.txtBrowseDotNetSolutionFile.Name =
"txtBrowseDotNetSolutionFile";
this.txtBrowseDotNetSolutionFile.Size = new
System.Drawing.Size(312, 20);
@@ -94,7 +98,7 @@ namespace NPanday.VisualStudio.Addin
// btnCancel
//
this.btnCancel.DialogResult =
System.Windows.Forms.DialogResult.Cancel;
- this.btnCancel.Location = new System.Drawing.Point(265, 172);
+ this.btnCancel.Location = new System.Drawing.Point(265, 245);
this.btnCancel.Margin = new System.Windows.Forms.Padding(2);
this.btnCancel.Name = "btnCancel";
this.btnCancel.Size = new System.Drawing.Size(104, 21);
@@ -105,7 +109,7 @@ namespace NPanday.VisualStudio.Addin
//
// btnGenerate
//
- this.btnGenerate.Location = new System.Drawing.Point(157, 172);
+ this.btnGenerate.Location = new System.Drawing.Point(157, 245);
this.btnGenerate.Margin = new System.Windows.Forms.Padding(2);
this.btnGenerate.Name = "btnGenerate";
this.btnGenerate.Size = new System.Drawing.Size(104, 21);
@@ -117,7 +121,7 @@ namespace NPanday.VisualStudio.Addin
// label1
//
this.label1.AutoSize = true;
- this.label1.Location = new System.Drawing.Point(10, 78);
+ this.label1.Location = new System.Drawing.Point(11, 49);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(53, 13);
this.label1.TabIndex = 10;
@@ -125,7 +129,7 @@ namespace NPanday.VisualStudio.Addin
//
// txtGroupId
//
- this.txtGroupId.Location = new System.Drawing.Point(118, 74);
+ this.txtGroupId.Location = new System.Drawing.Point(119, 46);
this.txtGroupId.Margin = new System.Windows.Forms.Padding(2);
this.txtGroupId.Name = "txtGroupId";
this.txtGroupId.Size = new System.Drawing.Size(171, 20);
@@ -134,7 +138,7 @@ namespace NPanday.VisualStudio.Addin
// lblSCM
//
this.lblSCM.AutoSize = true;
- this.lblSCM.Location = new System.Drawing.Point(8, 13);
+ this.lblSCM.Location = new System.Drawing.Point(9, 113);
this.lblSCM.Name = "lblSCM";
this.lblSCM.Size = new System.Drawing.Size(55, 13);
this.lblSCM.TabIndex = 12;
@@ -142,7 +146,7 @@ namespace NPanday.VisualStudio.Addin
//
// txtSCMTag
//
- this.txtSCMTag.Location = new System.Drawing.Point(118, 6);
+ this.txtSCMTag.Location = new System.Drawing.Point(119, 110);
this.txtSCMTag.Name = "txtSCMTag";
this.txtSCMTag.Size = new System.Drawing.Size(396, 20);
this.txtSCMTag.TabIndex = 13;
@@ -154,7 +158,7 @@ namespace NPanday.VisualStudio.Addin
// label2
//
this.label2.AutoSize = true;
- this.label2.Location = new System.Drawing.Point(10, 110);
+ this.label2.Location = new System.Drawing.Point(11, 81);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(45, 13);
this.label2.TabIndex = 14;
@@ -162,7 +166,7 @@ namespace NPanday.VisualStudio.Addin
//
// txtVersion
//
- this.txtVersion.Location = new System.Drawing.Point(118, 107);
+ this.txtVersion.Location = new System.Drawing.Point(119, 78);
this.txtVersion.Margin = new System.Windows.Forms.Padding(2);
this.txtVersion.Name = "txtVersion";
this.txtVersion.Size = new System.Drawing.Size(171, 20);
@@ -171,19 +175,60 @@ namespace NPanday.VisualStudio.Addin
// useMsDeployCheckBox
//
this.useMsDeployCheckBox.AutoSize = true;
- this.useMsDeployCheckBox.Location = new System.Drawing.Point(118,
141);
+ this.useMsDeployCheckBox.Location = new System.Drawing.Point(119,
208);
this.useMsDeployCheckBox.Name = "useMsDeployCheckBox";
this.useMsDeployCheckBox.Size = new System.Drawing.Size(264, 17);
this.useMsDeployCheckBox.TabIndex = 16;
this.useMsDeployCheckBox.Text = "Use Web Deploy 2.0 to package web
applications";
this.useMsDeployCheckBox.UseVisualStyleBackColor = true;
+ this.useMsDeployCheckBox.CheckedChanged += new
System.EventHandler(this.useMsDeployCheckBox_CheckedChanged);
+ //
+ // label3
+ //
+ this.label3.AutoSize = true;
+ this.label3.Location = new System.Drawing.Point(10, 145);
+ this.label3.Name = "label3";
+ this.label3.Size = new System.Drawing.Size(97, 13);
+ this.label3.TabIndex = 17;
+ this.label3.Text = "Web configuration:";
+ //
+ // label4
+ //
+ this.label4.AutoSize = true;
+ this.label4.Location = new System.Drawing.Point(10, 177);
+ this.label4.Name = "label4";
+ this.label4.Size = new System.Drawing.Size(101, 13);
+ this.label4.TabIndex = 18;
+ this.label4.Text = "Cloud configuration:";
+ //
+ // webConfigComboBox
+ //
+ this.webConfigComboBox.DropDownStyle =
System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.webConfigComboBox.FormattingEnabled = true;
+ this.webConfigComboBox.Location = new System.Drawing.Point(119,
142);
+ this.webConfigComboBox.Name = "webConfigComboBox";
+ this.webConfigComboBox.Size = new System.Drawing.Size(171, 21);
+ this.webConfigComboBox.TabIndex = 19;
+ //
+ // cloudConfigComboBox
+ //
+ this.cloudConfigComboBox.DropDownStyle =
System.Windows.Forms.ComboBoxStyle.DropDownList;
+ this.cloudConfigComboBox.FormattingEnabled = true;
+ this.cloudConfigComboBox.Location = new System.Drawing.Point(119,
174);
+ this.cloudConfigComboBox.Name = "cloudConfigComboBox";
+ this.cloudConfigComboBox.Size = new System.Drawing.Size(312, 21);
+ this.cloudConfigComboBox.TabIndex = 20;
//
// NPandayImportProjectForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(526, 204);
+ this.ClientSize = new System.Drawing.Size(526, 280);
this.ControlBox = false;
+ this.Controls.Add(this.cloudConfigComboBox);
+ this.Controls.Add(this.webConfigComboBox);
+ this.Controls.Add(this.label4);
+ this.Controls.Add(this.label3);
this.Controls.Add(this.useMsDeployCheckBox);
this.Controls.Add(this.txtVersion);
this.Controls.Add(this.label2);
@@ -220,5 +265,9 @@ namespace NPanday.VisualStudio.Addin
private System.Windows.Forms.Label label2;
private System.Windows.Forms.TextBox txtVersion;
private System.Windows.Forms.CheckBox useMsDeployCheckBox;
+ private System.Windows.Forms.Label label3;
+ private System.Windows.Forms.Label label4;
+ private System.Windows.Forms.ComboBox webConfigComboBox;
+ private System.Windows.Forms.ComboBox cloudConfigComboBox;
}
}
Modified:
incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.cs
URL:
http://svn.apache.org/viewvc/incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.cs?rev=1231188&r1=1231187&r2=1231188&view=diff
==============================================================================
---
incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.cs
(original)
+++
incubator/npanday/trunk/dotnet/assemblies/NPanday.VisualStudio.Addin/src/main/csharp/NPandayImportProjectForm.cs
Fri Jan 13 17:08:54 2012
@@ -112,6 +112,12 @@ namespace NPanday.VisualStudio.Addin
txtVersion.Text = version;
+ // assuming just one cloud project for now
+ List<string> cloudConfigurations = new List<string>();
+
+ // these could be per project, but assume they match up
for now
+ List<string> webConfigurations = new List<string>();
+
bool hasWebProjects = false, hasCloudProjects = false;
Solution2 solution = (Solution2)applicationObject.Solution;
foreach (Project project in solution.Projects)
@@ -119,10 +125,26 @@ namespace NPanday.VisualStudio.Addin
if (isWebProject(project))
{
hasWebProjects = true;
+ foreach (object c in
((object[])project.ConfigurationManager.ConfigurationRowNames))
+ {
+ string configuration = (string) c;
+ if (!webConfigurations.Contains(configuration))
+ {
+ webConfigurations.Add(configuration);
+ }
+ }
}
if (isCloudProject(project))
{
hasCloudProjects = true;
+
+ foreach (EnvDTE.ProjectItem item in
project.ProjectItems)
+ {
+ if (item.Name.EndsWith(".cscfg",
StringComparison.OrdinalIgnoreCase))
+ {
+ cloudConfigurations.Add(item.Name);
+ }
+ }
}
}
// disabled if there are cloud projects (must be on), or
if there are no web projects (not useful)
@@ -131,8 +153,25 @@ namespace NPanday.VisualStudio.Addin
// TODO: remember this, or have a default
// force to false if no web projects, force to true if
cloud projects
useMsDeployCheckBox.Checked = hasWebProjects ||
hasCloudProjects;
+
+ cloudConfigComboBox.Enabled = hasCloudProjects &&
cloudConfigurations.Count > 0;
+ cloudConfigComboBox.Items.Add("(Default)");
+
cloudConfigComboBox.Items.AddRange(cloudConfigurations.ToArray());
+ cloudConfigComboBox.SelectedItem = "(Default)";
+ webConfigComboBox.Enabled = hasWebProjects &&
webConfigurations.Count > 0;
+ webConfigComboBox.Items.Add("(Default)");
+
webConfigComboBox.Items.AddRange(webConfigurations.ToArray());
+ webConfigComboBox.SelectedItem = "(Default)";
+
+ if (hasWebProjects)
+ log.Debug("Web configurations: " + string.Join(", ",
webConfigurations.ToArray()));
+ if (hasCloudProjects)
+ log.Debug("Cloud configuration files: " +
string.Join(", ", cloudConfigurations.ToArray()));
+ }
+ catch (Exception e)
+ {
+ log.Debug("Error constructing the import form: " +
e.Message, e);
}
- catch { /*do nothing*/}
}
@@ -192,10 +231,22 @@ namespace NPanday.VisualStudio.Addin
private void btnGenerate_Click(object sender, EventArgs e)
{
+ string webConfig = null;
+ if (webConfigComboBox.SelectedItem != "(Default)")
+ {
+ webConfig = (string) webConfigComboBox.SelectedItem;
+ }
+
+ string cloudConfig = null;
+ if (cloudConfigComboBox.SelectedItem != "(Default)")
+ {
+ cloudConfig = (string)cloudConfigComboBox.SelectedItem;
+ }
+
//Refactored code for easier Unit Testing
try
{
- GeneratePom(txtBrowseDotNetSolutionFile.Text,
txtGroupId.Text.Trim(), txtVersion.Text.Trim(), txtSCMTag.Text,
useMsDeployCheckBox.Checked);
+ GeneratePom(txtBrowseDotNetSolutionFile.Text,
txtGroupId.Text.Trim(), txtVersion.Text.Trim(), txtSCMTag.Text,
useMsDeployCheckBox.Checked, webConfig, cloudConfig);
}
catch (Exception exception)
{
@@ -206,6 +257,11 @@ namespace NPanday.VisualStudio.Addin
protected void GeneratePom(String solutionFile, String groupId, String
version, String scmTag, bool useMsDeploy)
{
+ GeneratePom(solutionFile, groupId, version, scmTag, useMsDeploy,
null, null);
+ }
+
+ protected void GeneratePom(String solutionFile, String groupId, String
version, String scmTag, bool useMsDeploy, string webConfig, string cloudConfig)
+ {
string warningMsg = string.Empty;
String mavenVerRegex = "^[0-9]+(" + Regex.Escape(".") +
"?[0-9]+){0,3}$";
String hasAlpha = "[a-zA-Z]";
@@ -288,7 +344,7 @@ namespace NPanday.VisualStudio.Addin
validateSolutionStructure();
resyncAllArtifacts();
// TODO: nicer to have some sort of structure / flags for the
Msdeploy bit, or this dialog will get out of control over time - perhaps a
"project configuration" dialog can replace the test popup
- string[] generatedPoms =
ProjectImporter.NPandayImporter.ImportProject(file.FullName, groupId,
artifactId, version, scmTag, true, useMsDeploy, ref warningMsg);
+ string[] generatedPoms =
ProjectImporter.NPandayImporter.ImportProject(file.FullName, groupId,
artifactId, version, scmTag, true, useMsDeploy, webConfig, cloudConfig, ref
warningMsg);
string str = string.Format("NPanday Import Project has
Successfully Generated Pom Files!\n");
foreach (string pom in generatedPoms)
@@ -488,5 +544,10 @@ namespace NPanday.VisualStudio.Addin
// TODO: better location for utility
return Connect.IsFolder(project);
}
+
+ private void useMsDeployCheckBox_CheckedChanged(object sender,
EventArgs e)
+ {
+ webConfigComboBox.Enabled = useMsDeployCheckBox.Enabled;
+ }
}
}