Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve the message in the survey and the build #14820

Merged
merged 1 commit into from
Apr 23, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ PowerShellVersion = '7.2'
# Modules that must be imported into the global environment prior to importing this module
# RequiredModules = @(@{ModuleName="PSReadLine"; ModuleVersion="2.2.0-beta2"})

# NestedModules = @("Microsoft.Azure.PowerShell.Tools.AzPredictor.dll")
NestedModules = @("Microsoft.Azure.PowerShell.Tools.AzPredictor.dll")

ScriptsToProcess = @("PromptSurvey.ps1")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,10 @@ protected override void ProcessRecord()
var profileSettings = Settings.GetProfileSettings();
var surveyId = profileSettings?.SurveyId?.ToString(CultureInfo.InvariantCulture) ?? "000000";

var link = string.Format(OpenAzSurveyLink._SurveyLinkFormat, surveyId, CultureInfo.InvariantCulture);
var link = string.Format(OpenAzSurvey._SurveyLinkFormat, surveyId, CultureInfo.InvariantCulture);

Console.WriteLine($"Opening survey {link}");
Console.WriteLine($"Opening the default browser to {link}");

// TODO [mahuang] Ouput the link for user to copy/paste in case it's not open in the default browser.
var processStartInfo = new ProcessStartInfo();
processStartInfo.FileName = link;
processStartInfo.UseShellExecute = true;
Expand Down
11 changes: 5 additions & 6 deletions tools/Az.Tools.Predictor/Az.Tools.Predictor/InterceptSurvey.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -218,11 +218,10 @@ if ($shouldIntercept) {
}
}

Write-Host "---------------------------------------------------";
Write-Host "Survey:" -ForegroundColor $Host.PrivateData.VerboseBackgroundColor -BackgroundColor $host.PrivateData.VerboseForegroundColor -NoNewline;
Write-Host " How was your experience using Az predictor?";
Write-Host "";
Write-Host "Run " -NoNewline; Write-Host "Open-AzSurvey" -ForegroundColor $Host.PrivateData.VerboseBackgroundColor -BackgroundColor $host.PrivateData.VerboseForegroundColor -NoNewline; Write-Host " to give us your feedback.";
Write-Host "---------------------------------------------------";

Write-Host "Survey:" -ForegroundColor $Host.PrivateData.VerboseBackgroundColor -BackgroundColor $host.PrivateData.VerboseForegroundColor -NoNewline;
Write-Host " How was your experience using the Az Predictor module?";
Write-Host "";
Write-Host "Run " -NoNewline; Write-Host "Open-AzSurvey" -ForegroundColor $Host.PrivateData.VerboseBackgroundColor -BackgroundColor $host.PrivateData.VerboseForegroundColor -NoNewline; Write-Host " to give us your feedback.";
Write-Host "---------------------------------------------------";
}
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ internal static class JsonUtilities
/// 2. Use string instead of number for enums.
/// 3. Use the string values (camel case) for enum.
/// 4. Use the string values for the type <see cref="System.Version"/> in the properties and <see cref="System.Collections.Generic.IDictionary&lt;TKey, TValue>"/> keys.
/// 3. Skip the property if the value is null.
/// 5. Skip the property if the value is null.
/// </summary>
public static readonly JsonSerializerOptions DefaultSerializerOptions = new JsonSerializerOptions()
{
Expand Down