diff --git a/Source/v2/Meadow.Cli/Commands/Current/Dfu/DfuInstallCommand.cs b/Source/v2/Meadow.Cli/Commands/Current/Dfu/DfuInstallCommand.cs index f9708726..da88b689 100644 --- a/Source/v2/Meadow.Cli/Commands/Current/Dfu/DfuInstallCommand.cs +++ b/Source/v2/Meadow.Cli/Commands/Current/Dfu/DfuInstallCommand.cs @@ -7,7 +7,7 @@ namespace Meadow.CLI.Commands.DeviceManagement; -[Command("dfu install", Description = "Deploys a built Meadow application to a target device")] +[Command("dfu install", Description = "Install dfu-util to the host operating system")] public class DfuInstallCommand : BaseSettingsCommand { public const string DefaultVersion = "0.11"; @@ -44,11 +44,19 @@ protected override async ValueTask ExecuteCommand() { if (IsAdministrator()) { - await DfuUtils.InstallDfuUtil(FileManager.WildernessTempFolderPath, Version, CancellationToken); + try + { + await DfuUtils.InstallDfuUtil(FileManager.WildernessTempFolderPath, Version, CancellationToken); + } + catch (Exception ex) + { + throw new CommandException($"Failed to install DFU {Version}: " + ex.Message); + } + Logger?.LogInformation($"DFU {Version} installed successfully"); } else { - Logger?.LogError("To install DFU on Windows, you'll need to re-run the command from as an Administrator"); + Logger?.LogError("To install DFU on Windows, you'll need to run the command as an Administrator"); } } else if (RuntimeInformation.IsOSPlatform(OSPlatform.OSX)) diff --git a/Source/v2/Meadow.Cli/Meadow.CLI.csproj b/Source/v2/Meadow.Cli/Meadow.CLI.csproj index f95df498..4c487d5c 100644 --- a/Source/v2/Meadow.Cli/Meadow.CLI.csproj +++ b/Source/v2/Meadow.Cli/Meadow.CLI.csproj @@ -10,7 +10,7 @@ Wilderness Labs, Inc Wilderness Labs, Inc true - 2.0.19.0 + 2.0.20.0 AnyCPU http://developer.wildernesslabs.co/Meadow/Meadow.CLI/ https://github.com/WildernessLabs/Meadow.CLI diff --git a/Source/v2/Meadow.Cli/Properties/AssemblyInfo.cs b/Source/v2/Meadow.Cli/Properties/AssemblyInfo.cs index d0b748c5..272de141 100644 --- a/Source/v2/Meadow.Cli/Properties/AssemblyInfo.cs +++ b/Source/v2/Meadow.Cli/Properties/AssemblyInfo.cs @@ -6,6 +6,6 @@ namespace Meadow.CLI { public static class Constants { - public const string CLI_VERSION = "2.0.19.0"; + public const string CLI_VERSION = "2.0.20.0"; } } \ No newline at end of file