Skip to content

Commit

Permalink
Reduce risk of future breaking changes in upstream projects
Browse files Browse the repository at this point in the history
Learn about the developments in upstream projects now.
For the changes in the command-line interface library, see natemcmaster/CommandLineUtils#339
  • Loading branch information
Viir committed May 28, 2020
1 parent 839a8b8 commit 888af12
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 25 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="JavaScriptEngineSwitcher.ChakraCore" Version="3.4.4" />
<PackageReference Include="JavaScriptEngineSwitcher.ChakraCore.Native.linux-x64" Version="3.4.4" />
<PackageReference Include="JavaScriptEngineSwitcher.ChakraCore.Native.win-x64" Version="3.4.4" />
<PackageReference Include="JavaScriptEngineSwitcher.ChakraCore" Version="3.5.4" />
<PackageReference Include="JavaScriptEngineSwitcher.ChakraCore.Native.linux-x64" Version="3.5.4" />
<PackageReference Include="JavaScriptEngineSwitcher.ChakraCore.Native.win-x64" Version="3.5.4" />
<PackageReference Include="LibGit2Sharp" Version="0.26.2" />
<PackageReference Include="Microsoft.CodeAnalysis.CSharp.Scripting" Version="3.4.0" />
<PackageReference Include="Microsoft.CodeAnalysis.CSharp.Scripting" Version="3.6.0" />
<PackageReference Include="Mono.Posix.NETStandard" Version="1.0.0" />
<PackageReference Include="Newtonsoft.Json" Version="11.0.2" />
<PackageReference Include="System.Collections.Immutable" Version="1.5.0" />
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
<PackageReference Include="System.Collections.Immutable" Version="1.7.1" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,13 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Appveyor.TestLogger" Version="2.0.0" />
<PackageReference Include="FluentAssertions" Version="5.5.0" />
<PackageReference Include="Microsoft.AspNetCore.TestHost" Version="3.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.2.0" />
<PackageReference Include="morelinq" Version="3.0.0" />
<PackageReference Include="MSTest.TestAdapter" Version="2.0.0" />
<PackageReference Include="MSTest.TestFramework" Version="2.0.0" />
<PackageReference Include="Newtonsoft.Json" Version="11.0.2" />
<PackageReference Include="FluentAssertions" Version="5.10.3" />
<PackageReference Include="Microsoft.AspNetCore.TestHost" Version="3.1.4" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.6.1" />
<PackageReference Include="morelinq" Version="3.3.2" />
<PackageReference Include="MSTest.TestAdapter" Version="2.1.1" />
<PackageReference Include="MSTest.TestFramework" Version="2.1.1" />
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

<ItemGroup>
<PackageReference Include="FluffySpoon.AspNet.LetsEncrypt" Version="1.116.0" />
<PackageReference Include="Newtonsoft.Json" Version="11.0.2" />
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
</ItemGroup>

<ItemGroup>
Expand Down
18 changes: 9 additions & 9 deletions implement/elm-fullstack/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ CommandOption verboseLogOptionFromCommand(CommandLineApplication command) =>
var loweredElmOutputOption = buildConfigCmd.Option("--lowered-elm-output", "Path to a directory to write the lowered Elm app files.", CommandOptionType.SingleValue);
var fromOption = buildConfigCmd.Option("--from", "Location to load the app from.", CommandOptionType.SingleValue).IsRequired(allowEmptyStrings: false);

buildConfigCmd.ThrowOnUnexpectedArgument = false;
buildConfigCmd.UnrecognizedArgumentHandling = UnrecognizedArgumentHandling.StopParsingAndCollect;

buildConfigCmd.OnExecute(() =>
{
Expand All @@ -60,7 +60,7 @@ CommandOption verboseLogOptionFromCommand(CommandLineApplication command) =>
var (commandName, _, registerExecutableDirectoryOnPath) = CheckIfExecutableIsRegisteredOnPath();

installCmd.Description = "Installs the '" + commandName + "' command for the current user account.";
installCmd.ThrowOnUnexpectedArgument = true;
installCmd.UnrecognizedArgumentHandling = UnrecognizedArgumentHandling.Throw;

installCmd.OnExecute(() =>
{
Expand All @@ -71,7 +71,7 @@ CommandOption verboseLogOptionFromCommand(CommandLineApplication command) =>
app.Command("run-server", runServerCmd =>
{
runServerCmd.Description = "Run a web server supporting administration of an Elm-fullstack process via HTTP. This HTTP interface supports deployments, migrations, etc.";
runServerCmd.ThrowOnUnexpectedArgument = true;
runServerCmd.UnrecognizedArgumentHandling = UnrecognizedArgumentHandling.Throw;

var adminUrlsDefault = "http://*:4000";
string[] publicWebHostUrlsDefault = new[] { "http://*", "https://*" };
Expand Down Expand Up @@ -212,7 +212,7 @@ CommandOption verboseLogOptionFromCommand(CommandLineApplication command) =>
app.Command("deploy-app", deployAppCmd =>
{
deployAppCmd.Description = "Deploy an app to an Elm-fullstack process. By default, migrates from the previous Elm app state using the `migrate` function in the Elm app code.";
deployAppCmd.ThrowOnUnexpectedArgument = true;
deployAppCmd.UnrecognizedArgumentHandling = UnrecognizedArgumentHandling.Throw;

var getSiteAndPasswordFromOptions = siteAndSitePasswordOptionsOnCommand(deployAppCmd);
var fromOption = deployAppCmd.Option("--from", "Path to the app to deploy.", CommandOptionType.SingleValue).IsRequired(allowEmptyStrings: false);
Expand All @@ -239,7 +239,7 @@ CommandOption verboseLogOptionFromCommand(CommandLineApplication command) =>
app.Command("set-elm-app-state", setElmAppStateCmd =>
{
setElmAppStateCmd.Description = "Attempt to set the state of a backend Elm app using the common serialized representation.";
setElmAppStateCmd.ThrowOnUnexpectedArgument = true;
setElmAppStateCmd.UnrecognizedArgumentHandling = UnrecognizedArgumentHandling.Throw;

var siteAndPasswordFromCmd = siteAndSitePasswordOptionsOnCommand(setElmAppStateCmd);

Expand All @@ -264,7 +264,7 @@ CommandOption verboseLogOptionFromCommand(CommandLineApplication command) =>
app.Command("truncate-process-history", truncateProcessHistoryCmd =>
{
truncateProcessHistoryCmd.Description = "Remove parts of the process history from the persistent store, which are not needed to restore the process.";
truncateProcessHistoryCmd.ThrowOnUnexpectedArgument = true;
truncateProcessHistoryCmd.UnrecognizedArgumentHandling = UnrecognizedArgumentHandling.Throw;

var siteAndPasswordFromCmd = siteAndSitePasswordOptionsOnCommand(truncateProcessHistoryCmd);

Expand All @@ -286,7 +286,7 @@ CommandOption verboseLogOptionFromCommand(CommandLineApplication command) =>
app.Command("archive-process", archiveProcessCmd =>
{
archiveProcessCmd.Description = "Copy the files needed to restore the process and store those in a zip-archive.";
archiveProcessCmd.ThrowOnUnexpectedArgument = true;
archiveProcessCmd.UnrecognizedArgumentHandling = UnrecognizedArgumentHandling.Throw;

var siteAndPasswordFromCmd = siteAndSitePasswordOptionsOnCommand(archiveProcessCmd);

Expand Down Expand Up @@ -315,11 +315,11 @@ CommandOption verboseLogOptionFromCommand(CommandLineApplication command) =>
app.Command("user-secrets", userSecretsCmd =>
{
userSecretsCmd.Description = "Manage passwords for accessing the admin interfaces of servers.";
userSecretsCmd.ThrowOnUnexpectedArgument = true;
userSecretsCmd.UnrecognizedArgumentHandling = UnrecognizedArgumentHandling.Throw;

userSecretsCmd.Command("store", storeCmd =>
{
storeCmd.ThrowOnUnexpectedArgument = true;
storeCmd.UnrecognizedArgumentHandling = UnrecognizedArgumentHandling.Throw;

var siteArgument = storeCmd.Argument("site", "Site where to use this secret as password.", multipleValues: false).IsRequired(allowEmptyStrings: false);
var passwordArgument = storeCmd.Argument("password", "Password to use for authentication.", multipleValues: false).IsRequired(allowEmptyStrings: false);
Expand Down
2 changes: 1 addition & 1 deletion implement/elm-fullstack/elm-fullstack.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="McMaster.Extensions.CommandLineUtils" Version="2.5.0" />
<PackageReference Include="McMaster.Extensions.CommandLineUtils" Version="3.0.0" />
</ItemGroup>

<ItemGroup>
Expand Down

0 comments on commit 888af12

Please sign in to comment.