From 9698557d7d6af5845eb459e9509f4e5bc5340288 Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Tue, 8 Aug 2023 13:40:46 +0100 Subject: [PATCH 01/11] Support Old and new LibUsbDotNet nugets. --- Meadow.CLI.Core/Constants.cs | 2 +- Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs | 37 ++++++++- Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj | 80 +++++++++++++++++++ .../DeviceManagement/FlashOsCommand.cs | 10 ++- Meadow.CLI/Meadow.CLI.Win10.csproj | 70 ++++++++++++++++ MeadowCLI.sln | 18 +++++ 6 files changed, 212 insertions(+), 5 deletions(-) create mode 100644 Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj create mode 100644 Meadow.CLI/Meadow.CLI.Win10.csproj diff --git a/Meadow.CLI.Core/Constants.cs b/Meadow.CLI.Core/Constants.cs index 9cb2e6ad..c95d1c66 100644 --- a/Meadow.CLI.Core/Constants.cs +++ b/Meadow.CLI.Core/Constants.cs @@ -7,7 +7,7 @@ namespace Meadow.CLI.Core { public static class Constants { - public const string CLI_VERSION = "1.2.0.0"; + public const string CLI_VERSION = "1.2.2.0"; public const ushort HCOM_PROTOCOL_PREVIOUS_VERSION_NUMBER = 0x0006; public const ushort HCOM_PROTOCOL_CURRENT_VERSION_NUMBER = 0x0007; // Used for transmission public const string WILDERNESS_LABS_USB_VID = "2E6A"; diff --git a/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs b/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs index 16582d70..0efe7a2a 100644 --- a/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs +++ b/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs @@ -33,8 +33,11 @@ public static bool CheckForValidDevice() return false; } } - +#if WIN_10 + public static UsbRegistry GetDeviceInBootloaderMode() +#else public static IUsbDevice GetDeviceInBootloaderMode() +#endif { var allDevices = GetDevicesInBootloaderMode(); if (allDevices.Count() > 1) @@ -50,9 +53,22 @@ public static IUsbDevice GetDeviceInBootloaderMode() return device; } - +#if WIN_10 + public static IEnumerable GetDevicesInBootloaderMode() +#else public static IEnumerable GetDevicesInBootloaderMode() +#endif { +#if WIN_10 + + var allDevices = UsbDevice.AllDevices.ToList(); + var ourDevices = allDevices.Where(d => d.Device.Info.ProductString == _usbStmName); + if (ourDevices.Count() < 1) + { + throw new DeviceNotFoundException("No Devices found. Connect a device in bootloader mode. If the device is in bootloader mode, please update the device driver. See instructions at https://wldrn.es/usbdriver"); + } + return ourDevices; +#else using (UsbContext context = new UsbContext()) { var allDevices = context.List(); @@ -63,9 +79,20 @@ public static IEnumerable GetDevicesInBootloaderMode() } return ourDevices; } +#endif } +#if WIN_10 + public static string GetDeviceSerial(UsbRegistry device) + { + if (device != null && device.DeviceProperties != null) + return device.DeviceProperties["SerialNumber"].ToString(); + else + return string.Empty; + } +#else public static string GetDeviceSerial(IUsbDevice device) + { var serialNumber = string.Empty; @@ -81,6 +108,7 @@ public static string GetDeviceSerial(IUsbDevice device) return serialNumber; } +#endif public enum DfuFlashFormat { @@ -143,8 +171,11 @@ public static Task FlashLatest(ILogger? logger = null, DfuFlashFormat form return FlashFile(fileName: fileName, logger: logger, format: DfuUtils.DfuFlashFormat.ConsoleOut); } - +#if WIN_10 + public static async Task FlashFile(string fileName, UsbRegistry? device = null, ILogger? logger = null, DfuFlashFormat format = DfuFlashFormat.Percent) +#else public static async Task FlashFile(string fileName, IUsbDevice? device = null, ILogger? logger = null, DfuFlashFormat format = DfuFlashFormat.Percent) +#endif { logger ??= NullLogger.Instance; device ??= GetDeviceInBootloaderMode(); diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj new file mode 100644 index 00000000..05af584c --- /dev/null +++ b/Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj @@ -0,0 +1,80 @@ + + + + net6.0 + AnyCPU + true + MeadowCLIKey.snk + false + false + false + preview + enable + True + 1.2.0.0 + + + + true + + + + TRACE;DEBUG;NET;NET6_0;NETCOREAPP;WIN_10 + 4 + + + true + TRACE;RELEASE;NET;NET6_0;NETCOREAPP;WIN_10 + 4 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + runtime; build; native; contentfiles; analyzers; buildtransitive + all + + + + + + + + + + + + + + + + + diff --git a/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs b/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs index 057c0bf7..17868108 100644 --- a/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs +++ b/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs @@ -1,6 +1,11 @@ using CliFx.Attributes; using CliFx.Infrastructure; +#if WIN_10 +using LibUsbDotNet.Main; +#else +using LibUsbDotNet; using LibUsbDotNet.LibUsb; +#endif using Meadow.CLI.Commands.Utility; using Meadow.CLI.Core; using Meadow.CLI.Core.DeviceManagement; @@ -182,8 +187,11 @@ async Task FindCurrentMeadowDevice(string serialPortName, st async Task SetMeadowToDfuMode(string serialPortName, CancellationToken cancellationToken) { var dfuAttempts = 0; - +#if WIN_10 + UsbRegistry dfuDevice; +#else IUsbDevice dfuDevice; +#endif while (true) { try diff --git a/Meadow.CLI/Meadow.CLI.Win10.csproj b/Meadow.CLI/Meadow.CLI.Win10.csproj new file mode 100644 index 00000000..934c312f --- /dev/null +++ b/Meadow.CLI/Meadow.CLI.Win10.csproj @@ -0,0 +1,70 @@ + + + + Exe + net6.0 + true + Wilderness Labs, Inc + meadow + WildernessLabs.Meadow.CLI + Peter Moody, Adrian Stevens, Brian Kim, Pete Garafano, Dominique Louis + Wilderness Labs, Inc + true + 1.2.2.0 + AnyCPU + http://developer.wildernesslabs.co/Meadow/Meadow.Foundation/ + icon.png + https://github.com/WildernessLabs/Meadow.CLI + Meadow, Meadow.Foundation, Meadow.CLI + Command-line interface for Meadow + false + false + false + false + meadow + latest + Copyright 2020-2022 Wilderness Labs + + + + TRACE;WIN_10;DEBUG;NET;NET6_0;NETCOREAPP + 4 + + + true + TRACE;RELEASE;NET;NET6_0;NETCOREAPP;WIN_10 + 4 + + + + + + + + + + + + + + + + + + + + + + + + + + + Always + + + + + + + diff --git a/MeadowCLI.sln b/MeadowCLI.sln index 16466935..7fa8ece0 100644 --- a/MeadowCLI.sln +++ b/MeadowCLI.sln @@ -11,6 +11,12 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Hcom.6.0.0", "Meadow EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Core.6.0.0", "Meadow.CLI.Core\Meadow.CLI.Core.6.0.0.csproj", "{AD70EEEA-731F-445A-8AE8-6432B587D24C}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Core.Win10", "Meadow.CLI.Core\Meadow.CLI.Core.Win10.csproj", "{7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Win10", "Meadow.CLI\Meadow.CLI.Win10.csproj", "{C1ADC097-F805-4A35-9706-DF243D22E31E}" +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Win10", "Win10", "{9284F290-8070-422D-8C98-8A18ED4A8F04}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -33,6 +39,14 @@ Global {AD70EEEA-731F-445A-8AE8-6432B587D24C}.Debug|Any CPU.Build.0 = Debug|Any CPU {AD70EEEA-731F-445A-8AE8-6432B587D24C}.Release|Any CPU.ActiveCfg = Release|Any CPU {AD70EEEA-731F-445A-8AE8-6432B587D24C}.Release|Any CPU.Build.0 = Release|Any CPU + {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Debug|Any CPU.Build.0 = Debug|Any CPU + {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Release|Any CPU.ActiveCfg = Release|Any CPU + {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Release|Any CPU.Build.0 = Release|Any CPU + {C1ADC097-F805-4A35-9706-DF243D22E31E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {C1ADC097-F805-4A35-9706-DF243D22E31E}.Debug|Any CPU.Build.0 = Debug|Any CPU + {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.ActiveCfg = Release|Any CPU + {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -40,4 +54,8 @@ Global GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {6FA96453-7A9C-4F78-89EE-676C4611C899} EndGlobalSection + GlobalSection(NestedProjects) = preSolution + {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F} = {9284F290-8070-422D-8C98-8A18ED4A8F04} + {C1ADC097-F805-4A35-9706-DF243D22E31E} = {9284F290-8070-422D-8C98-8A18ED4A8F04} + EndGlobalSection EndGlobal From 6f2009f45ecef5b76aa7a096964acbfb44e7fac4 Mon Sep 17 00:00:00 2001 From: CartBlanche Date: Tue, 8 Aug 2023 16:40:29 +0100 Subject: [PATCH 02/11] Make sure flashing works in Windows. --- Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs | 18 +++++++++++++++--- Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj | 5 +++-- Meadow.CLI/Meadow.CLI.Win10.csproj | 2 +- 3 files changed, 19 insertions(+), 6 deletions(-) diff --git a/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs b/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs index 0efe7a2a..47dd63fd 100644 --- a/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs +++ b/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs @@ -61,8 +61,8 @@ public static IEnumerable GetDevicesInBootloaderMode() { #if WIN_10 - var allDevices = UsbDevice.AllDevices.ToList(); - var ourDevices = allDevices.Where(d => d.Device.Info.ProductString == _usbStmName); + var allDevices = UsbDevice.AllDevices; + var ourDevices = allDevices.Where(d => d.DeviceProperties["FriendlyName"].ToString() == _usbStmName); if (ourDevices.Count() < 1) { throw new DeviceNotFoundException("No Devices found. Connect a device in bootloader mode. If the device is in bootloader mode, please update the device driver. See instructions at https://wldrn.es/usbdriver"); @@ -86,7 +86,19 @@ public static IEnumerable GetDevicesInBootloaderMode() public static string GetDeviceSerial(UsbRegistry device) { if (device != null && device.DeviceProperties != null) - return device.DeviceProperties["SerialNumber"].ToString(); + { + switch (Environment.OSVersion.Platform) + { + case PlatformID.Win32NT: + var deviceID = device.DeviceProperties["DeviceID"].ToString(); + if (!string.IsNullOrWhiteSpace(deviceID)) + return deviceID.Substring(deviceID.LastIndexOf("\\") + 1); + else + return string.Empty; + default: + return device.DeviceProperties["SerialNumber"].ToString(); + } + } else return string.Empty; } diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj index 05af584c..1d462c81 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj @@ -11,13 +11,13 @@ preview enable True - 1.2.0.0 + 1.2.2.0 true - + TRACE;DEBUG;NET;NET6_0;NETCOREAPP;WIN_10 4 @@ -27,6 +27,7 @@ TRACE;RELEASE;NET;NET6_0;NETCOREAPP;WIN_10 4 + diff --git a/Meadow.CLI/Meadow.CLI.Win10.csproj b/Meadow.CLI/Meadow.CLI.Win10.csproj index 934c312f..c75a9a05 100644 --- a/Meadow.CLI/Meadow.CLI.Win10.csproj +++ b/Meadow.CLI/Meadow.CLI.Win10.csproj @@ -27,7 +27,7 @@ - TRACE;WIN_10;DEBUG;NET;NET6_0;NETCOREAPP + TRACE;DEBUG;NET;NET6_0;NETCOREAPP;WIN_10 4 From e15fd1aad29131fefcd5db3aef9fe35b9a46dc8f Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Tue, 8 Aug 2023 21:12:27 +0100 Subject: [PATCH 03/11] Create separate solution and rename old stuff 'Classic'. Add to CI --- .github/workflows/dotnet.yml | 10 ++++- Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs | 13 +++++- ....csproj => Meadow.CLI.Core.Classic.csproj} | 3 +- .../DeviceManagement/FlashOsCommand.cs | 9 ++-- ...Win10.csproj => Meadow.CLI.Classic.csproj} | 4 +- MeadowCLI.Classic.sln | 45 +++++++++++++++++++ MeadowCLI.sln | 16 ------- 7 files changed, 74 insertions(+), 26 deletions(-) rename Meadow.CLI.Core/{Meadow.CLI.Core.Win10.csproj => Meadow.CLI.Core.Classic.csproj} (94%) rename Meadow.CLI/{Meadow.CLI.Win10.csproj => Meadow.CLI.Classic.csproj} (97%) create mode 100644 MeadowCLI.Classic.sln diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index f4971fa5..40e8aae8 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -62,10 +62,16 @@ jobs: - name: Add MSBuild to Path uses: microsoft/setup-msbuild@v1.1 - - name: Restore dependencies + - name: Restore Classic dependencies + run: dotnet restore main/MeadowCLI.Classic.sln /p:Configuration=Release + + - name: Build Classic CLI + run: dotnet build main/MeadowCLI.Classic.sln /p:Configuration=Release + + - name: Restore normal dependencies run: dotnet restore main/MeadowCLI.sln /p:Configuration=Release - - name: Build + - name: Build normal CLI run: dotnet build main/MeadowCLI.sln /p:Configuration=Release - name: Upload nuget Artifacts for internal testing diff --git a/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs b/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs index 47dd63fd..f34b60f1 100644 --- a/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs +++ b/Meadow.CLI.Core/Internals/Dfu/DfuUtils.cs @@ -62,7 +62,18 @@ public static IEnumerable GetDevicesInBootloaderMode() #if WIN_10 var allDevices = UsbDevice.AllDevices; - var ourDevices = allDevices.Where(d => d.DeviceProperties["FriendlyName"].ToString() == _usbStmName); + IEnumerable ourDevices; + + switch (Environment.OSVersion.Platform) + { + case PlatformID.Win32NT: + ourDevices = allDevices.Where(d => d.DeviceProperties["FriendlyName"].ToString() == _usbStmName); + break; + default: + ourDevices = allDevices.Where(d => d.DeviceProperties["DeviceDesc"].ToString() == _usbStmName); + break; + } + if (ourDevices.Count() < 1) { throw new DeviceNotFoundException("No Devices found. Connect a device in bootloader mode. If the device is in bootloader mode, please update the device driver. See instructions at https://wldrn.es/usbdriver"); diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj similarity index 94% rename from Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj rename to Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj index 1d462c81..07cc86bc 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.Win10.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj @@ -19,8 +19,9 @@ - TRACE;DEBUG;NET;NET6_0;NETCOREAPP;WIN_10 + TRACE;WIN_10;DEBUG;NET;NET6_0;NETCOREAPP 4 + false true diff --git a/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs b/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs index 17868108..84e02e6b 100644 --- a/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs +++ b/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs @@ -3,7 +3,6 @@ #if WIN_10 using LibUsbDotNet.Main; #else -using LibUsbDotNet; using LibUsbDotNet.LibUsb; #endif using Meadow.CLI.Commands.Utility; @@ -117,7 +116,7 @@ async Task ValidateVersionAndPromptUserToEraseFlash(IConsole console, Canc { // We just flashed the OS so it will show the current version // But the runtime hasn't been updated yet so should match the previous OS version - Version previousOsVersion; + System.Version previousOsVersion; string checkName; try @@ -130,18 +129,18 @@ async Task ValidateVersionAndPromptUserToEraseFlash(IConsole console, Canc } else { - previousOsVersion = new Version(runtimeVersion.Split(' ')[0]); + previousOsVersion = new System.Version(runtimeVersion.Split(' ')[0]); } checkName = "runtime"; } catch { - previousOsVersion = new Version(MINIMUM_OS_VERSION); + previousOsVersion = new System.Version(MINIMUM_OS_VERSION); checkName = "OS"; } // If less that B6.1 flash - if (previousOsVersion.CompareTo(new Version(MINIMUM_OS_VERSION)) <= 0) + if (previousOsVersion.CompareTo(new System.Version(MINIMUM_OS_VERSION)) <= 0) { // Ask User 1st before wiping Logger.LogInformation($"Your {checkName} version is older than {MINIMUM_OS_VERSION} (or unreadable). A flash erase is highly recommended."); diff --git a/Meadow.CLI/Meadow.CLI.Win10.csproj b/Meadow.CLI/Meadow.CLI.Classic.csproj similarity index 97% rename from Meadow.CLI/Meadow.CLI.Win10.csproj rename to Meadow.CLI/Meadow.CLI.Classic.csproj index c75a9a05..227ffa22 100644 --- a/Meadow.CLI/Meadow.CLI.Win10.csproj +++ b/Meadow.CLI/Meadow.CLI.Classic.csproj @@ -35,6 +35,7 @@ TRACE;RELEASE;NET;NET6_0;NETCOREAPP;WIN_10 4 + @@ -52,6 +53,7 @@ + @@ -65,6 +67,6 @@ - + diff --git a/MeadowCLI.Classic.sln b/MeadowCLI.Classic.sln new file mode 100644 index 00000000..5ade3ef4 --- /dev/null +++ b/MeadowCLI.Classic.sln @@ -0,0 +1,45 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.0.32014.148 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Meadow.CLI.Test", "Meadow.CLI.Test\Meadow.CLI.Test.csproj", "{0A7887E0-9DCA-4072-91D8-6409C5562243}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Hcom.6.0.0", "Meadow.Hcom\Meadow.Hcom.6.0.0.csproj", "{197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Core.Classic", "Meadow.CLI.Core\Meadow.CLI.Core.Classic.csproj", "{7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Classic", "Meadow.CLI\Meadow.CLI.Classic.csproj", "{C1ADC097-F805-4A35-9706-DF243D22E31E}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {0A7887E0-9DCA-4072-91D8-6409C5562243}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {0A7887E0-9DCA-4072-91D8-6409C5562243}.Debug|Any CPU.Build.0 = Debug|Any CPU + {0A7887E0-9DCA-4072-91D8-6409C5562243}.Release|Any CPU.ActiveCfg = Release|Any CPU + {0A7887E0-9DCA-4072-91D8-6409C5562243}.Release|Any CPU.Build.0 = Release|Any CPU + {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Debug|Any CPU.Build.0 = Debug|Any CPU + {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Release|Any CPU.ActiveCfg = Release|Any CPU + {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Release|Any CPU.Build.0 = Release|Any CPU + {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Debug|Any CPU.Build.0 = Debug|Any CPU + {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Release|Any CPU.ActiveCfg = Release|Any CPU + {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Release|Any CPU.Build.0 = Release|Any CPU + {C1ADC097-F805-4A35-9706-DF243D22E31E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {C1ADC097-F805-4A35-9706-DF243D22E31E}.Debug|Any CPU.Build.0 = Debug|Any CPU + {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.ActiveCfg = Release|Any CPU + {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {6FA96453-7A9C-4F78-89EE-676C4611C899} + EndGlobalSection + GlobalSection(NestedProjects) = preSolution + EndGlobalSection +EndGlobal diff --git a/MeadowCLI.sln b/MeadowCLI.sln index 7fa8ece0..dda49b96 100644 --- a/MeadowCLI.sln +++ b/MeadowCLI.sln @@ -11,12 +11,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Hcom.6.0.0", "Meadow EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Core.6.0.0", "Meadow.CLI.Core\Meadow.CLI.Core.6.0.0.csproj", "{AD70EEEA-731F-445A-8AE8-6432B587D24C}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Core.Win10", "Meadow.CLI.Core\Meadow.CLI.Core.Win10.csproj", "{7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Win10", "Meadow.CLI\Meadow.CLI.Win10.csproj", "{C1ADC097-F805-4A35-9706-DF243D22E31E}" -EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Win10", "Win10", "{9284F290-8070-422D-8C98-8A18ED4A8F04}" -EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -39,14 +33,6 @@ Global {AD70EEEA-731F-445A-8AE8-6432B587D24C}.Debug|Any CPU.Build.0 = Debug|Any CPU {AD70EEEA-731F-445A-8AE8-6432B587D24C}.Release|Any CPU.ActiveCfg = Release|Any CPU {AD70EEEA-731F-445A-8AE8-6432B587D24C}.Release|Any CPU.Build.0 = Release|Any CPU - {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Debug|Any CPU.Build.0 = Debug|Any CPU - {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Release|Any CPU.ActiveCfg = Release|Any CPU - {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Release|Any CPU.Build.0 = Release|Any CPU - {C1ADC097-F805-4A35-9706-DF243D22E31E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {C1ADC097-F805-4A35-9706-DF243D22E31E}.Debug|Any CPU.Build.0 = Debug|Any CPU - {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.ActiveCfg = Release|Any CPU - {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -55,7 +41,5 @@ Global SolutionGuid = {6FA96453-7A9C-4F78-89EE-676C4611C899} EndGlobalSection GlobalSection(NestedProjects) = preSolution - {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F} = {9284F290-8070-422D-8C98-8A18ED4A8F04} - {C1ADC097-F805-4A35-9706-DF243D22E31E} = {9284F290-8070-422D-8C98-8A18ED4A8F04} EndGlobalSection EndGlobal From ec2b31883822de561a57f9426172e8bff5b72922 Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Tue, 8 Aug 2023 21:38:22 +0100 Subject: [PATCH 04/11] Remove Test reference from Classic.sln --- MeadowCLI.Classic.sln | 6 ------ 1 file changed, 6 deletions(-) diff --git a/MeadowCLI.Classic.sln b/MeadowCLI.Classic.sln index 5ade3ef4..34373af1 100644 --- a/MeadowCLI.Classic.sln +++ b/MeadowCLI.Classic.sln @@ -3,8 +3,6 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio Version 17 VisualStudioVersion = 17.0.32014.148 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Meadow.CLI.Test", "Meadow.CLI.Test\Meadow.CLI.Test.csproj", "{0A7887E0-9DCA-4072-91D8-6409C5562243}" -EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Hcom.6.0.0", "Meadow.Hcom\Meadow.Hcom.6.0.0.csproj", "{197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Core.Classic", "Meadow.CLI.Core\Meadow.CLI.Core.Classic.csproj", "{7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}" @@ -17,10 +15,6 @@ Global Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {0A7887E0-9DCA-4072-91D8-6409C5562243}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {0A7887E0-9DCA-4072-91D8-6409C5562243}.Debug|Any CPU.Build.0 = Debug|Any CPU - {0A7887E0-9DCA-4072-91D8-6409C5562243}.Release|Any CPU.ActiveCfg = Release|Any CPU - {0A7887E0-9DCA-4072-91D8-6409C5562243}.Release|Any CPU.Build.0 = Release|Any CPU {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Debug|Any CPU.Build.0 = Debug|Any CPU {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Release|Any CPU.ActiveCfg = Release|Any CPU From 6f300808bc30bcce36db7cdc47a6632b0f456e56 Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Fri, 11 Aug 2023 19:48:45 +0100 Subject: [PATCH 05/11] Bump nuget version numbers. --- Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj | 10 +++++----- Meadow.CLI/Meadow.CLI.Classic.csproj | 16 ++++++++-------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj index 07cc86bc..3decc375 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj @@ -51,16 +51,16 @@ - - + + - + - - + + runtime; build; native; contentfiles; analyzers; buildtransitive all diff --git a/Meadow.CLI/Meadow.CLI.Classic.csproj b/Meadow.CLI/Meadow.CLI.Classic.csproj index 227ffa22..4a0af21c 100644 --- a/Meadow.CLI/Meadow.CLI.Classic.csproj +++ b/Meadow.CLI/Meadow.CLI.Classic.csproj @@ -44,15 +44,15 @@ - - - - - + + + + + - - - + + + From 15448ac8a0b7a3ec1a7082cad364fc3be1dd4844 Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Fri, 11 Aug 2023 19:56:57 +0100 Subject: [PATCH 06/11] Build to separate directory and create downloadable artifacts. --- .github/workflows/dotnet.yml | 6 ++++++ Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj | 2 ++ Meadow.CLI/Meadow.CLI.Classic.csproj | 4 +++- 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index 40e8aae8..faad9833 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -68,6 +68,12 @@ jobs: - name: Build Classic CLI run: dotnet build main/MeadowCLI.Classic.sln /p:Configuration=Release + - name: Upload nuget Artifacts for internal testing + uses: actions/upload-artifact@v2 + with: + name: Meadow.CLI.Classic.nuget.${{ ENV.CLI_RELEASE_VERSION }} + path: 'main\Meadow.CLI.Classic\bin\Release\*.nupkg' + - name: Restore normal dependencies run: dotnet restore main/MeadowCLI.sln /p:Configuration=Release diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj index 3decc375..a2248325 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj @@ -19,12 +19,14 @@ + ..\Meadow.CLI.Core.Classic\bin\Debug TRACE;WIN_10;DEBUG;NET;NET6_0;NETCOREAPP 4 false true + ..\Meadow.CLI.Core.Classic\bin\Release TRACE;RELEASE;NET;NET6_0;NETCOREAPP;WIN_10 4 diff --git a/Meadow.CLI/Meadow.CLI.Classic.csproj b/Meadow.CLI/Meadow.CLI.Classic.csproj index 4a0af21c..d5ab9226 100644 --- a/Meadow.CLI/Meadow.CLI.Classic.csproj +++ b/Meadow.CLI/Meadow.CLI.Classic.csproj @@ -27,12 +27,14 @@ + ..\Meadow.CLI.Classic\bin\Debug TRACE;DEBUG;NET;NET6_0;NETCOREAPP;WIN_10 4 true - TRACE;RELEASE;NET;NET6_0;NETCOREAPP;WIN_10 + ..\Meadow.CLI.Classic\bin\Release + TRACE;WIN_10;RELEASE;NET;NET6_0;NETCOREAPP 4 From ef369f7e2ff00d100a4f27d026adc013c2281618 Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Mon, 14 Aug 2023 10:59:06 +0100 Subject: [PATCH 07/11] Make all Classic projects net5.0 for now. --- .../Meadow.CLI.Core.Classic.csproj | 8 +++--- Meadow.CLI/CliFxConsoleLoggerProvider.cs | 4 +++ Meadow.CLI/Commands/App/DeployAppCommand.cs | 12 ++++++++ .../Cloud/Package/CreatePackageCommand.cs | 8 ++++++ .../Cloud/Package/PublishPackageCommand.cs | 4 +++ .../Cloud/Package/UploadPackageCommand.cs | 4 +++ .../DeviceManagement/FlashEspCommand.cs | 4 +++ .../DeviceManagement/FlashOsCommand.cs | 28 +++++++++++++++++++ .../Commands/Esp32/WriteEsp32FileCommand.cs | 12 ++++++++ .../Commands/Files/DeleteAllFilesCommand.cs | 8 ++++++ .../Commands/Files/DeleteFileCommand.cs | 8 ++++++ .../Commands/Files/InitialFileBytesCommand.cs | 8 ++++++ Meadow.CLI/Commands/Files/ListFilesCommand.cs | 8 ++++++ Meadow.CLI/Commands/Files/WriteFileCommand.cs | 12 ++++++++ Meadow.CLI/Commands/MeadowCommand.cs | 4 +++ Meadow.CLI/Commands/MeadowSerialCommand.cs | 3 +- .../Commands/Mono/MonoDisableCommand.cs | 5 ++++ Meadow.CLI/Commands/Mono/MonoEnableCommand.cs | 4 +++ .../Commands/Mono/MonoUpdateRuntimeCommand.cs | 8 ++++++ Meadow.CLI/Commands/Qspi/QspiInitCommand.cs | 4 +++ Meadow.CLI/Commands/Qspi/QspiReadCommand.cs | 4 +++ Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs | 4 +++ .../Commands/Trace/TraceEnableCommand.cs | 4 +++ .../Commands/Trace/TraceLevelCommand.cs | 4 +++ Meadow.CLI/Commands/Utility/DebugCommand.cs | 4 +++ .../Commands/Utility/DownloadOsCommand.cs | 8 ++++++ .../Commands/Utility/InstallDfuUtilCommand.cs | 21 +++++++++----- Meadow.CLI/Meadow.CLI.Classic.csproj | 10 +++---- Meadow.Hcom/Meadow.Hcom.Classic.csproj | 11 ++++++++ MeadowCLI.Classic.sln | 12 ++++---- 30 files changed, 215 insertions(+), 23 deletions(-) create mode 100644 Meadow.Hcom/Meadow.Hcom.Classic.csproj diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj index a2248325..71504d14 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj @@ -1,7 +1,7 @@  - net6.0 + net5.0 AnyCPU true MeadowCLIKey.snk @@ -45,8 +45,8 @@ - - + + @@ -79,6 +79,6 @@ - + diff --git a/Meadow.CLI/CliFxConsoleLoggerProvider.cs b/Meadow.CLI/CliFxConsoleLoggerProvider.cs index 80497377..22dbc7f5 100644 --- a/Meadow.CLI/CliFxConsoleLoggerProvider.cs +++ b/Meadow.CLI/CliFxConsoleLoggerProvider.cs @@ -53,6 +53,10 @@ public ILogger CreateLogger(string categoryName) => public class CliFxConsoleLoggerProviderConfig { +#if WIN_10 + public LogLevel LogLevel { get; } +#else public LogLevel LogLevel {get; init; } +#endif } } diff --git a/Meadow.CLI/Commands/App/DeployAppCommand.cs b/Meadow.CLI/Commands/App/DeployAppCommand.cs index 3c3fd3e7..0a67cb74 100644 --- a/Meadow.CLI/Commands/App/DeployAppCommand.cs +++ b/Meadow.CLI/Commands/App/DeployAppCommand.cs @@ -17,17 +17,29 @@ public class DeployAppCommand : MeadowSerialCommand 'f', Description = "The path to the application to deploy to the app", IsRequired = true)] +#if WIN_10 + public string File { get; } +#else public string File { get; init; } +#endif [CommandOption( "nolink", 'n', Description = "A list of assemblies to skip linking (trimming) on", IsRequired = false)] +#if WIN_10 + public IList NoLink { get; } = null; +#else public IList NoLink { get; init; } = null; +#endif [CommandOption("includePdbs", 'i', Description = "Include the PDB files on deploy to enable debugging", IsRequired = false)] +#if WIN_10 + public bool IncludePdbs { get; } = true; +#else public bool IncludePdbs { get; init; } = true; +#endif public DeployAppCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/Cloud/Package/CreatePackageCommand.cs b/Meadow.CLI/Commands/Cloud/Package/CreatePackageCommand.cs index b388b62f..d0d4f944 100644 --- a/Meadow.CLI/Commands/Cloud/Package/CreatePackageCommand.cs +++ b/Meadow.CLI/Commands/Cloud/Package/CreatePackageCommand.cs @@ -27,10 +27,18 @@ public CreateCommand(ILoggerFactory loggerFactory, PackageManager packageManager } [CommandOption("applicationPath", 'a', Description = "The path to the application directory", IsRequired = false)] +#if WIN_10 + public string ApplicationPath { get; } +#else public string ApplicationPath { get; init; } +#endif [CommandOption("osVersion", 'v', Description = "Version of Meadow OS to include in package", IsRequired = false)] +#if WIN_10 + public string OsVersion { get; } +#else public string OsVersion { get; init; } +#endif public async ValueTask ExecuteAsync(IConsole console) diff --git a/Meadow.CLI/Commands/Cloud/Package/PublishPackageCommand.cs b/Meadow.CLI/Commands/Cloud/Package/PublishPackageCommand.cs index 4e0ff720..eb766cb1 100644 --- a/Meadow.CLI/Commands/Cloud/Package/PublishPackageCommand.cs +++ b/Meadow.CLI/Commands/Cloud/Package/PublishPackageCommand.cs @@ -33,7 +33,11 @@ public PublishCommand(ILoggerFactory loggerFactory, PackageService packageServic } [CommandOption("packageId", 'p', Description = "ID of the package to publish", IsRequired = true)] +#if WIN_10 + public string PackageId { get; } +#else public string PackageId { get; init; } +#endif [CommandOption("collectionId", 'c', Description = "The target collection for publishing", IsRequired = true)] public string CollectionId { get; set; } [CommandOption("metadata", 'm', Description = "Pass through metadata", IsRequired = false)] diff --git a/Meadow.CLI/Commands/Cloud/Package/UploadPackageCommand.cs b/Meadow.CLI/Commands/Cloud/Package/UploadPackageCommand.cs index b01db5b7..0106eb40 100644 --- a/Meadow.CLI/Commands/Cloud/Package/UploadPackageCommand.cs +++ b/Meadow.CLI/Commands/Cloud/Package/UploadPackageCommand.cs @@ -39,7 +39,11 @@ public UploadCommand(ILoggerFactory loggerFactory, UserService userService, Pack } [CommandOption("mpakPath", 'p', Description = "The full path of the mpak file", IsRequired = true)] +#if WIN_10 + public string MpakPath { get; } +#else public string MpakPath { get; init; } +#endif [CommandOption("orgId", 'o', Description = "OrgId to upload to", IsRequired = false)] public string OrgId { get; set; } diff --git a/Meadow.CLI/Commands/DeviceManagement/FlashEspCommand.cs b/Meadow.CLI/Commands/DeviceManagement/FlashEspCommand.cs index 12ba5ca2..d64b21c1 100644 --- a/Meadow.CLI/Commands/DeviceManagement/FlashEspCommand.cs +++ b/Meadow.CLI/Commands/DeviceManagement/FlashEspCommand.cs @@ -14,7 +14,11 @@ namespace Meadow.CLI.Commands.DeviceManagement public class FlashEspCommand : MeadowSerialCommand { [CommandOption("osVersion", 'v', Description = "Flash the ESP from a specific downloaded OS version - x.x.x.x")] +#if WIN_10 + public string OSVersion { get; } +#else public string OSVersion { get; init; } +#endif public FlashEspCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs b/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs index 84e02e6b..fd72d3da 100644 --- a/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs +++ b/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs @@ -29,25 +29,53 @@ public FlashOsCommand(DownloadManager downloadManager, ILoggerFactory loggerFact } [CommandOption("osFile", 'o', Description = "Path to the Meadow OS binary")] +#if WIN_10 + public string OSFile { get; } +#else public string OSFile { get; init; } +#endif [CommandOption("runtimeFile", 'r', Description = "Path to the Meadow Runtime binary")] +#if WIN_10 + public string RuntimeFile { get; } +#else public string RuntimeFile { get; init; } +#endif [CommandOption("skipDfu", 'd', Description = "Skip DFU flash")] +#if WIN_10 + public bool SkipOS { get; } +#else public bool SkipOS { get; init; } +#endif [CommandOption("skipEsp", 'e', Description = "Skip ESP flash")] +#if WIN_10 + public bool SkipEsp { get; } +#else public bool SkipEsp { get; init; } +#endif [CommandOption("skipRuntime", 'k', Description = "Skip updating the runtime")] +#if WIN_10 + public bool SkipRuntime { get; } +#else public bool SkipRuntime { get; init; } +#endif [CommandOption("dontPrompt", 'p', Description = "Don't show bulk erase prompt")] +#if WIN_10 + public bool DontPrompt { get; } +#else public bool DontPrompt { get; init; } +#endif [CommandOption("osVersion", 'v', Description = "Flash a specific downloaded OS version - x.x.x.x")] +#if WIN_10 + public string OSVersion { get; } +#else public string OSVersion { get; init; } +#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Esp32/WriteEsp32FileCommand.cs b/Meadow.CLI/Commands/Esp32/WriteEsp32FileCommand.cs index eadcb67c..d3e6f5fb 100644 --- a/Meadow.CLI/Commands/Esp32/WriteEsp32FileCommand.cs +++ b/Meadow.CLI/Commands/Esp32/WriteEsp32FileCommand.cs @@ -17,16 +17,28 @@ public class WriteEsp32FileCommand : MeadowSerialCommand 'f', Description = "The file to write to the Meadow's ESP32 File System", IsRequired = true)] +#if WIN_10 + public string Filename { get; } +#else public string Filename { get; init; } +#endif [CommandOption( "targetFile", 't', Description = "The filename to use on the Meadow's ESP32 File System")] +#if WIN_10 + public string TargetFilename { get; } +#else public string TargetFilename { get; init; } +#endif [CommandOption("McuDestAddress", Description = "Where file is stored in MCU's internal flash e.g. 0x10000", IsRequired = true)] +#if WIN_10 + public string McuDestAddress { get; } +#else public string McuDestAddress { get; init; } +#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/DeleteAllFilesCommand.cs b/Meadow.CLI/Commands/Files/DeleteAllFilesCommand.cs index 08ea3b15..3a66702e 100644 --- a/Meadow.CLI/Commands/Files/DeleteAllFilesCommand.cs +++ b/Meadow.CLI/Commands/Files/DeleteAllFilesCommand.cs @@ -13,12 +13,20 @@ namespace Meadow.CLI.Commands.Files [Command("file delete all", Description = "Delete all files from the Meadow File System")] public class DeleteAllFilesCommand : MeadowSerialCommand { +#if WIN_10 + public IList Files { get; } +#else public IList Files { get; init; } +#endif #if USE_PARTITIONS [CommandOption("Partition", 'p', Description = "The partition to write to on the Meadow")] #endif +#if WIN_10 + public int Partition { get; } = 0; +#else public int Partition { get; init; } = 0; +#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/DeleteFileCommand.cs b/Meadow.CLI/Commands/Files/DeleteFileCommand.cs index 01264c09..f8d45a67 100644 --- a/Meadow.CLI/Commands/Files/DeleteFileCommand.cs +++ b/Meadow.CLI/Commands/Files/DeleteFileCommand.cs @@ -17,12 +17,20 @@ public class DeleteFileCommand : MeadowSerialCommand 'f', Description = "The file(s) to delete from the Meadow Files System", IsRequired = true)] +#if WIN_10 + public IList Files { get; } +#else public IList Files { get; init; } +#endif #if USE_PARTITIONS [CommandOption("Partition", 'p', Description = "The partition to write to on the Meadow")] #endif +#if WIN_10 + public uint Partition { get; } = 0; +#else public uint Partition { get; init; } = 0; +#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/InitialFileBytesCommand.cs b/Meadow.CLI/Commands/Files/InitialFileBytesCommand.cs index 0eb39474..fe183eb5 100644 --- a/Meadow.CLI/Commands/Files/InitialFileBytesCommand.cs +++ b/Meadow.CLI/Commands/Files/InitialFileBytesCommand.cs @@ -13,14 +13,22 @@ public class InitialFileBytesCommand : MeadowSerialCommand #if USE_PARTITIONS [CommandOption("Partition", 'p', Description = "The partition to list the files")] #endif +#if WIN_10 + public uint Partition { get; } = 0; +#else public uint Partition { get; init; } = 0; +#endif [CommandOption( "file", 'f', Description = "The file to get the bytes from", IsRequired = true)] +#if WIN_10 + public string Filename { get; } +#else public string Filename { get; init; } +#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/ListFilesCommand.cs b/Meadow.CLI/Commands/Files/ListFilesCommand.cs index 27b60778..8e2931b2 100644 --- a/Meadow.CLI/Commands/Files/ListFilesCommand.cs +++ b/Meadow.CLI/Commands/Files/ListFilesCommand.cs @@ -17,10 +17,18 @@ public class ListFilesCommand : MeadowSerialCommand #endif public const int FileSystemBlockSize = 4096; +#if WIN_10 + public int Partition { get; } = 0; +#else public int Partition { get; init; } = 0; +#endif [CommandOption("includeCrcs", 'i', Description = "Include the CRCs of the files")] +#if WIN_10 + public bool IncludeCrcs { get; } +#else public bool IncludeCrcs { get; init; } +#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/WriteFileCommand.cs b/Meadow.CLI/Commands/Files/WriteFileCommand.cs index a7726ceb..873a9581 100644 --- a/Meadow.CLI/Commands/Files/WriteFileCommand.cs +++ b/Meadow.CLI/Commands/Files/WriteFileCommand.cs @@ -19,18 +19,30 @@ public class WritesFileCommand : MeadowSerialCommand 'f', Description = "The file(s) to write to the Meadow Files System", IsRequired = true)] +#if WIN_10 + public IList Files { get; } +#else public IList Files { get; init; } +#endif [CommandOption( "targetFiles", 't', Description = "The filename(s) to use on the Meadow File System")] +#if WIN_10 + public IList TargetFileNames { get; } = Array.Empty(); +#else public IList TargetFileNames { get; init; } = Array.Empty(); +#endif #if USE_PARTITIONS [CommandOption("Partition", 'p', Description = "The partition to write to on the Meadow")] #endif +#if WIN_10 + public int Partition { get; } = 0; +#else public int Partition { get; init; } = 0; +#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/MeadowCommand.cs b/Meadow.CLI/Commands/MeadowCommand.cs index 7b8c44f6..97121790 100644 --- a/Meadow.CLI/Commands/MeadowCommand.cs +++ b/Meadow.CLI/Commands/MeadowCommand.cs @@ -21,7 +21,11 @@ private protected MeadowCommand(DownloadManager downloadManager, ILoggerFactory } [CommandOption("LogVerbosity", 'g', Description = "Log verbosity")] +#if WIN_10 + public string[] Verbosity { get; } +#else public string[] Verbosity { get; init; } +#endif public virtual async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/MeadowSerialCommand.cs b/Meadow.CLI/Commands/MeadowSerialCommand.cs index 4b43df4f..c37ea420 100644 --- a/Meadow.CLI/Commands/MeadowSerialCommand.cs +++ b/Meadow.CLI/Commands/MeadowSerialCommand.cs @@ -7,6 +7,7 @@ using Microsoft.Extensions.Logging; using System; using System.Linq; +using System.Runtime.InteropServices; using System.Threading.Tasks; namespace Meadow.CLI.Commands @@ -56,7 +57,7 @@ private string GetSerialPort() private bool PortExists(string name) { - if (OperatingSystem.IsWindows()) + if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) { // windows is case-insensitive return System.IO.Ports.SerialPort.GetPortNames().Contains(name, StringComparer.InvariantCultureIgnoreCase); diff --git a/Meadow.CLI/Commands/Mono/MonoDisableCommand.cs b/Meadow.CLI/Commands/Mono/MonoDisableCommand.cs index 41c530d6..663f6f0d 100644 --- a/Meadow.CLI/Commands/Mono/MonoDisableCommand.cs +++ b/Meadow.CLI/Commands/Mono/MonoDisableCommand.cs @@ -19,7 +19,12 @@ public MonoDisableCommand(DownloadManager downloadManager, ILoggerFactory logger } [CommandOption("force",'f', Description = "Send the Mono Disable Command even if Mono is already disabled")] +#if WIN_10 + public bool Force { get; } +#else public bool Force { get; init; } +#endif + public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Mono/MonoEnableCommand.cs b/Meadow.CLI/Commands/Mono/MonoEnableCommand.cs index 0ce39fdd..39c6ce02 100644 --- a/Meadow.CLI/Commands/Mono/MonoEnableCommand.cs +++ b/Meadow.CLI/Commands/Mono/MonoEnableCommand.cs @@ -19,7 +19,11 @@ public MonoEnableCommand(DownloadManager downloadManager, ILoggerFactory loggerF } [CommandOption("force",'f', Description = "Send the Mono Enable Command even if Mono is already enabled")] +#if WIN_10 + public bool Force { get; } +#else public bool Force { get; init; } +#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Mono/MonoUpdateRuntimeCommand.cs b/Meadow.CLI/Commands/Mono/MonoUpdateRuntimeCommand.cs index d6434373..64910c79 100644 --- a/Meadow.CLI/Commands/Mono/MonoUpdateRuntimeCommand.cs +++ b/Meadow.CLI/Commands/Mono/MonoUpdateRuntimeCommand.cs @@ -11,10 +11,18 @@ namespace Meadow.CLI.Commands.Mono public class MonoUpdateRuntimeCommand : MeadowSerialCommand { [CommandOption("filename",'f', Description = "The local name of the mono runtime file - Default is empty")] +#if WIN_10 + public string Filename { get; } +#else public string Filename {get; init;} +#endif [CommandOption("osVersion", 'v', Description = "Flash the mono runtime from a specific downloaded OS version - x.x.x.x")] +#if WIN_10 + public string OSVersion { get; } +#else public string OSVersion { get; init; } +#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Qspi/QspiInitCommand.cs b/Meadow.CLI/Commands/Qspi/QspiInitCommand.cs index e3bdbc0e..dc23a0e1 100644 --- a/Meadow.CLI/Commands/Qspi/QspiInitCommand.cs +++ b/Meadow.CLI/Commands/Qspi/QspiInitCommand.cs @@ -13,7 +13,11 @@ public class QspiInitCommand : MeadowSerialCommand private readonly ILogger _logger; [CommandOption("value",'v', Description = "The QSPI Value to initialize", IsRequired = true)] +#if WIN_10 + public int Value { get; } +#else public int Value {get; init;} +#endif public QspiInitCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/Qspi/QspiReadCommand.cs b/Meadow.CLI/Commands/Qspi/QspiReadCommand.cs index f4414d68..13b0aa05 100644 --- a/Meadow.CLI/Commands/Qspi/QspiReadCommand.cs +++ b/Meadow.CLI/Commands/Qspi/QspiReadCommand.cs @@ -13,7 +13,11 @@ public class QspiReadCommand : MeadowSerialCommand private readonly ILogger _logger; [CommandOption("value",'v', Description = "The QSPI Value to read", IsRequired = true)] +#if WIN_10 + public int Value { get; } +#else public int Value {get; init;} +#endif public QspiReadCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs b/Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs index 0904e57f..e10ea4f4 100644 --- a/Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs +++ b/Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs @@ -13,7 +13,11 @@ public class QspiWriteCommand : MeadowSerialCommand private readonly ILogger _logger; [CommandOption("value",'v', Description = "The QSPI Value to write", IsRequired = true)] +#if WIN_10 + public int Value { get; } +#else public int Value {get; init;} +#endif public QspiWriteCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/Trace/TraceEnableCommand.cs b/Meadow.CLI/Commands/Trace/TraceEnableCommand.cs index 6593eb46..3f97646a 100644 --- a/Meadow.CLI/Commands/Trace/TraceEnableCommand.cs +++ b/Meadow.CLI/Commands/Trace/TraceEnableCommand.cs @@ -19,7 +19,11 @@ public TraceEnableCommand(DownloadManager downloadManager, ILoggerFactory logger } [CommandOption("Level", 'l', Description = "The desired trace level")] +#if WIN_10 + public uint? TraceLevel { get; } +#else public uint? TraceLevel { get; init; } +#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Trace/TraceLevelCommand.cs b/Meadow.CLI/Commands/Trace/TraceLevelCommand.cs index 2de264bb..fe8b43fd 100644 --- a/Meadow.CLI/Commands/Trace/TraceLevelCommand.cs +++ b/Meadow.CLI/Commands/Trace/TraceLevelCommand.cs @@ -19,7 +19,11 @@ public TraceLevelCommand(DownloadManager downloadManager, ILoggerFactory loggerF } [CommandOption("TraceLevel",'t', Description = "The desired trace level")] +#if WIN_10 + public uint TraceLevel { get; } +#else public uint TraceLevel { get; init; } +#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Utility/DebugCommand.cs b/Meadow.CLI/Commands/Utility/DebugCommand.cs index 818787c0..a601d9f3 100644 --- a/Meadow.CLI/Commands/Utility/DebugCommand.cs +++ b/Meadow.CLI/Commands/Utility/DebugCommand.cs @@ -22,7 +22,11 @@ public DebugCommand(DownloadManager downloadManager, ILoggerFactory loggerFactor // VS 2017 - 4022 // VS 2015 - 4020 [CommandOption("DebugPort", 'p', Description = "The port to run the debug server on")] +#if WIN_10 + public int Port { get; } = 4024; +#else public int Port { get; init; } = 4024; +#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Utility/DownloadOsCommand.cs b/Meadow.CLI/Commands/Utility/DownloadOsCommand.cs index 6067ee45..b5d08eee 100644 --- a/Meadow.CLI/Commands/Utility/DownloadOsCommand.cs +++ b/Meadow.CLI/Commands/Utility/DownloadOsCommand.cs @@ -14,10 +14,18 @@ public DownloadOsCommand(DownloadManager downloadManager, ILoggerFactory loggerF } [CommandOption("force", 'f', Description = "Force re-download of the OS", IsRequired = false)] +#if WIN_10 + public bool Force { get; } = false; +#else public bool Force { get; init; } = false; +#endif [CommandOption("osVersion", 'v', Description = "Download a specific OS version - x.x.x.x", IsRequired = false)] +#if WIN_10 + public string OsVersion { get; } +#else public string OsVersion { get; init; } +#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Utility/InstallDfuUtilCommand.cs b/Meadow.CLI/Commands/Utility/InstallDfuUtilCommand.cs index 70df8cbb..a7b7a58f 100644 --- a/Meadow.CLI/Commands/Utility/InstallDfuUtilCommand.cs +++ b/Meadow.CLI/Commands/Utility/InstallDfuUtilCommand.cs @@ -1,4 +1,5 @@ using System; +using System.Runtime.InteropServices; using System.Runtime.Versioning; using System.Security.Principal; using System.Threading.Tasks; @@ -23,7 +24,7 @@ public override async ValueTask ExecuteAsync(IConsole console) var cancellationToken = console.RegisterCancellationHandler(); await base.ExecuteAsync(console); - if (OperatingSystem.IsWindows()) + if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) { if(IsAdministrator()) { @@ -34,22 +35,28 @@ public override async ValueTask ExecuteAsync(IConsole console) _logger.LogInformation("To install on Windows, you'll need to open a Command Prompt or Terminal as an administrator"); } } - else if (OperatingSystem.IsMacOS()) + else if (RuntimeInformation.IsOSPlatform(OSPlatform.OSX)) { _logger.LogInformation("To install on macOS, run: brew install dfu-util"); - } else if (OperatingSystem.IsLinux()) + } else if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux)) { _logger.LogInformation( "To install on Linux, use the package manager to install the dfu-util package"); } } - [SupportedOSPlatform("windows")] private static bool IsAdministrator() { - var identity = WindowsIdentity.GetCurrent(); - var principal = new WindowsPrincipal(identity); - return principal.IsInRole(WindowsBuiltInRole.Administrator); + if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) + { + var identity = WindowsIdentity.GetCurrent(); + var principal = new WindowsPrincipal(identity); + return principal.IsInRole(WindowsBuiltInRole.Administrator); + } + else + { + return false; + } } } } \ No newline at end of file diff --git a/Meadow.CLI/Meadow.CLI.Classic.csproj b/Meadow.CLI/Meadow.CLI.Classic.csproj index d5ab9226..861d9f82 100644 --- a/Meadow.CLI/Meadow.CLI.Classic.csproj +++ b/Meadow.CLI/Meadow.CLI.Classic.csproj @@ -2,7 +2,7 @@ Exe - net6.0 + net5.0 true Wilderness Labs, Inc meadow @@ -28,13 +28,13 @@ ..\Meadow.CLI.Classic\bin\Debug - TRACE;DEBUG;NET;NET6_0;NETCOREAPP;WIN_10 + TRACE;DEBUG;NET;NETCOREAPP;WIN_10 4 true ..\Meadow.CLI.Classic\bin\Release - TRACE;WIN_10;RELEASE;NET;NET6_0;NETCOREAPP + TRACE;WIN_10;RELEASE;NET;NETCOREAPP 4 @@ -51,11 +51,11 @@ - - + + diff --git a/Meadow.Hcom/Meadow.Hcom.Classic.csproj b/Meadow.Hcom/Meadow.Hcom.Classic.csproj new file mode 100644 index 00000000..e792d465 --- /dev/null +++ b/Meadow.Hcom/Meadow.Hcom.Classic.csproj @@ -0,0 +1,11 @@ + + + + net5.0 + enable + preview + true + MeadowCLIKey.snk + + + diff --git a/MeadowCLI.Classic.sln b/MeadowCLI.Classic.sln index 34373af1..493d515a 100644 --- a/MeadowCLI.Classic.sln +++ b/MeadowCLI.Classic.sln @@ -3,22 +3,18 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio Version 17 VisualStudioVersion = 17.0.32014.148 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Hcom.6.0.0", "Meadow.Hcom\Meadow.Hcom.6.0.0.csproj", "{197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}" -EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Core.Classic", "Meadow.CLI.Core\Meadow.CLI.Core.Classic.csproj", "{7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Classic", "Meadow.CLI\Meadow.CLI.Classic.csproj", "{C1ADC097-F805-4A35-9706-DF243D22E31E}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Hcom.Classic", "Meadow.Hcom\Meadow.Hcom.Classic.csproj", "{3918812D-B2C2-416D-8A64-10FD2B932852}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Debug|Any CPU.Build.0 = Debug|Any CPU - {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Release|Any CPU.ActiveCfg = Release|Any CPU - {197F26BB-F7CD-4ADA-9A15-ADBA36F825E1}.Release|Any CPU.Build.0 = Release|Any CPU {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Debug|Any CPU.Build.0 = Debug|Any CPU {7C3AF1F9-4FD3-45EE-844E-60D18D64CA1F}.Release|Any CPU.ActiveCfg = Release|Any CPU @@ -27,6 +23,10 @@ Global {C1ADC097-F805-4A35-9706-DF243D22E31E}.Debug|Any CPU.Build.0 = Debug|Any CPU {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.ActiveCfg = Release|Any CPU {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.Build.0 = Release|Any CPU + {3918812D-B2C2-416D-8A64-10FD2B932852}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {3918812D-B2C2-416D-8A64-10FD2B932852}.Debug|Any CPU.Build.0 = Debug|Any CPU + {3918812D-B2C2-416D-8A64-10FD2B932852}.Release|Any CPU.ActiveCfg = Release|Any CPU + {3918812D-B2C2-416D-8A64-10FD2B932852}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE From a5ec0fe588b9bd6fa230882dce549c6aa69055fd Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Mon, 14 Aug 2023 16:33:59 +0100 Subject: [PATCH 08/11] Switch to net6 --- Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj | 2 +- Meadow.CLI/Meadow.CLI.Classic.csproj | 2 +- Meadow.Hcom/Meadow.Hcom.Classic.csproj | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj index 71504d14..4e25b2d6 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj @@ -1,7 +1,7 @@  - net5.0 + net6.0 AnyCPU true MeadowCLIKey.snk diff --git a/Meadow.CLI/Meadow.CLI.Classic.csproj b/Meadow.CLI/Meadow.CLI.Classic.csproj index 861d9f82..0c30fd7b 100644 --- a/Meadow.CLI/Meadow.CLI.Classic.csproj +++ b/Meadow.CLI/Meadow.CLI.Classic.csproj @@ -2,7 +2,7 @@ Exe - net5.0 + net6.0 true Wilderness Labs, Inc meadow diff --git a/Meadow.Hcom/Meadow.Hcom.Classic.csproj b/Meadow.Hcom/Meadow.Hcom.Classic.csproj index e792d465..434f30fe 100644 --- a/Meadow.Hcom/Meadow.Hcom.Classic.csproj +++ b/Meadow.Hcom/Meadow.Hcom.Classic.csproj @@ -1,7 +1,7 @@  - net5.0 + net6.0 enable preview true From 0eedbd8abe0eaac8a38ad46933841d3b7bce83a8 Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Tue, 15 Aug 2023 10:58:35 +0100 Subject: [PATCH 09/11] Remove IFDEF around init; --- Meadow.CLI/CliFxConsoleLoggerProvider.cs | 4 --- Meadow.CLI/Commands/App/DeployAppCommand.cs | 12 -------- .../Cloud/Package/CreatePackageCommand.cs | 9 ------ .../Cloud/Package/PublishPackageCommand.cs | 7 ++--- .../Cloud/Package/UploadPackageCommand.cs | 4 --- .../DeviceManagement/FlashEspCommand.cs | 4 --- .../DeviceManagement/FlashOsCommand.cs | 28 ------------------- .../Commands/Esp32/WriteEsp32FileCommand.cs | 12 -------- .../Commands/Files/DeleteAllFilesCommand.cs | 8 ------ .../Commands/Files/DeleteFileCommand.cs | 8 ------ .../Commands/Files/InitialFileBytesCommand.cs | 8 ------ Meadow.CLI/Commands/Files/ListFilesCommand.cs | 8 ------ Meadow.CLI/Commands/Files/WriteFileCommand.cs | 12 -------- Meadow.CLI/Commands/MeadowCommand.cs | 4 --- .../Commands/Mono/MonoDisableCommand.cs | 5 ---- Meadow.CLI/Commands/Mono/MonoEnableCommand.cs | 4 --- .../Commands/Mono/MonoUpdateRuntimeCommand.cs | 8 ------ Meadow.CLI/Commands/Qspi/QspiInitCommand.cs | 4 --- Meadow.CLI/Commands/Qspi/QspiReadCommand.cs | 4 --- Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs | 4 --- .../Commands/Trace/TraceEnableCommand.cs | 4 --- .../Commands/Trace/TraceLevelCommand.cs | 4 --- Meadow.CLI/Commands/Utility/DebugCommand.cs | 4 --- .../Commands/Utility/DownloadOsCommand.cs | 8 ------ 24 files changed, 3 insertions(+), 174 deletions(-) diff --git a/Meadow.CLI/CliFxConsoleLoggerProvider.cs b/Meadow.CLI/CliFxConsoleLoggerProvider.cs index 22dbc7f5..80497377 100644 --- a/Meadow.CLI/CliFxConsoleLoggerProvider.cs +++ b/Meadow.CLI/CliFxConsoleLoggerProvider.cs @@ -53,10 +53,6 @@ public ILogger CreateLogger(string categoryName) => public class CliFxConsoleLoggerProviderConfig { -#if WIN_10 - public LogLevel LogLevel { get; } -#else public LogLevel LogLevel {get; init; } -#endif } } diff --git a/Meadow.CLI/Commands/App/DeployAppCommand.cs b/Meadow.CLI/Commands/App/DeployAppCommand.cs index 0a67cb74..3c3fd3e7 100644 --- a/Meadow.CLI/Commands/App/DeployAppCommand.cs +++ b/Meadow.CLI/Commands/App/DeployAppCommand.cs @@ -17,29 +17,17 @@ public class DeployAppCommand : MeadowSerialCommand 'f', Description = "The path to the application to deploy to the app", IsRequired = true)] -#if WIN_10 - public string File { get; } -#else public string File { get; init; } -#endif [CommandOption( "nolink", 'n', Description = "A list of assemblies to skip linking (trimming) on", IsRequired = false)] -#if WIN_10 - public IList NoLink { get; } = null; -#else public IList NoLink { get; init; } = null; -#endif [CommandOption("includePdbs", 'i', Description = "Include the PDB files on deploy to enable debugging", IsRequired = false)] -#if WIN_10 - public bool IncludePdbs { get; } = true; -#else public bool IncludePdbs { get; init; } = true; -#endif public DeployAppCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/Cloud/Package/CreatePackageCommand.cs b/Meadow.CLI/Commands/Cloud/Package/CreatePackageCommand.cs index d0d4f944..f73be363 100644 --- a/Meadow.CLI/Commands/Cloud/Package/CreatePackageCommand.cs +++ b/Meadow.CLI/Commands/Cloud/Package/CreatePackageCommand.cs @@ -27,19 +27,10 @@ public CreateCommand(ILoggerFactory loggerFactory, PackageManager packageManager } [CommandOption("applicationPath", 'a', Description = "The path to the application directory", IsRequired = false)] -#if WIN_10 - public string ApplicationPath { get; } -#else public string ApplicationPath { get; init; } -#endif [CommandOption("osVersion", 'v', Description = "Version of Meadow OS to include in package", IsRequired = false)] -#if WIN_10 - public string OsVersion { get; } -#else public string OsVersion { get; init; } -#endif - public async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Cloud/Package/PublishPackageCommand.cs b/Meadow.CLI/Commands/Cloud/Package/PublishPackageCommand.cs index eb766cb1..1019dc78 100644 --- a/Meadow.CLI/Commands/Cloud/Package/PublishPackageCommand.cs +++ b/Meadow.CLI/Commands/Cloud/Package/PublishPackageCommand.cs @@ -33,15 +33,14 @@ public PublishCommand(ILoggerFactory loggerFactory, PackageService packageServic } [CommandOption("packageId", 'p', Description = "ID of the package to publish", IsRequired = true)] -#if WIN_10 - public string PackageId { get; } -#else public string PackageId { get; init; } -#endif + [CommandOption("collectionId", 'c', Description = "The target collection for publishing", IsRequired = true)] public string CollectionId { get; set; } + [CommandOption("metadata", 'm', Description = "Pass through metadata", IsRequired = false)] public string Metadata { get; set; } + [CommandOption("host", Description = "Optionally set a host (default is https://www.meadowcloud.co)", IsRequired = false)] public string Host { get; set; } diff --git a/Meadow.CLI/Commands/Cloud/Package/UploadPackageCommand.cs b/Meadow.CLI/Commands/Cloud/Package/UploadPackageCommand.cs index 0106eb40..b01db5b7 100644 --- a/Meadow.CLI/Commands/Cloud/Package/UploadPackageCommand.cs +++ b/Meadow.CLI/Commands/Cloud/Package/UploadPackageCommand.cs @@ -39,11 +39,7 @@ public UploadCommand(ILoggerFactory loggerFactory, UserService userService, Pack } [CommandOption("mpakPath", 'p', Description = "The full path of the mpak file", IsRequired = true)] -#if WIN_10 - public string MpakPath { get; } -#else public string MpakPath { get; init; } -#endif [CommandOption("orgId", 'o', Description = "OrgId to upload to", IsRequired = false)] public string OrgId { get; set; } diff --git a/Meadow.CLI/Commands/DeviceManagement/FlashEspCommand.cs b/Meadow.CLI/Commands/DeviceManagement/FlashEspCommand.cs index d64b21c1..12ba5ca2 100644 --- a/Meadow.CLI/Commands/DeviceManagement/FlashEspCommand.cs +++ b/Meadow.CLI/Commands/DeviceManagement/FlashEspCommand.cs @@ -14,11 +14,7 @@ namespace Meadow.CLI.Commands.DeviceManagement public class FlashEspCommand : MeadowSerialCommand { [CommandOption("osVersion", 'v', Description = "Flash the ESP from a specific downloaded OS version - x.x.x.x")] -#if WIN_10 - public string OSVersion { get; } -#else public string OSVersion { get; init; } -#endif public FlashEspCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs b/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs index fd72d3da..84e02e6b 100644 --- a/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs +++ b/Meadow.CLI/Commands/DeviceManagement/FlashOsCommand.cs @@ -29,53 +29,25 @@ public FlashOsCommand(DownloadManager downloadManager, ILoggerFactory loggerFact } [CommandOption("osFile", 'o', Description = "Path to the Meadow OS binary")] -#if WIN_10 - public string OSFile { get; } -#else public string OSFile { get; init; } -#endif [CommandOption("runtimeFile", 'r', Description = "Path to the Meadow Runtime binary")] -#if WIN_10 - public string RuntimeFile { get; } -#else public string RuntimeFile { get; init; } -#endif [CommandOption("skipDfu", 'd', Description = "Skip DFU flash")] -#if WIN_10 - public bool SkipOS { get; } -#else public bool SkipOS { get; init; } -#endif [CommandOption("skipEsp", 'e', Description = "Skip ESP flash")] -#if WIN_10 - public bool SkipEsp { get; } -#else public bool SkipEsp { get; init; } -#endif [CommandOption("skipRuntime", 'k', Description = "Skip updating the runtime")] -#if WIN_10 - public bool SkipRuntime { get; } -#else public bool SkipRuntime { get; init; } -#endif [CommandOption("dontPrompt", 'p', Description = "Don't show bulk erase prompt")] -#if WIN_10 - public bool DontPrompt { get; } -#else public bool DontPrompt { get; init; } -#endif [CommandOption("osVersion", 'v', Description = "Flash a specific downloaded OS version - x.x.x.x")] -#if WIN_10 - public string OSVersion { get; } -#else public string OSVersion { get; init; } -#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Esp32/WriteEsp32FileCommand.cs b/Meadow.CLI/Commands/Esp32/WriteEsp32FileCommand.cs index d3e6f5fb..eadcb67c 100644 --- a/Meadow.CLI/Commands/Esp32/WriteEsp32FileCommand.cs +++ b/Meadow.CLI/Commands/Esp32/WriteEsp32FileCommand.cs @@ -17,28 +17,16 @@ public class WriteEsp32FileCommand : MeadowSerialCommand 'f', Description = "The file to write to the Meadow's ESP32 File System", IsRequired = true)] -#if WIN_10 - public string Filename { get; } -#else public string Filename { get; init; } -#endif [CommandOption( "targetFile", 't', Description = "The filename to use on the Meadow's ESP32 File System")] -#if WIN_10 - public string TargetFilename { get; } -#else public string TargetFilename { get; init; } -#endif [CommandOption("McuDestAddress", Description = "Where file is stored in MCU's internal flash e.g. 0x10000", IsRequired = true)] -#if WIN_10 - public string McuDestAddress { get; } -#else public string McuDestAddress { get; init; } -#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/DeleteAllFilesCommand.cs b/Meadow.CLI/Commands/Files/DeleteAllFilesCommand.cs index 3a66702e..08ea3b15 100644 --- a/Meadow.CLI/Commands/Files/DeleteAllFilesCommand.cs +++ b/Meadow.CLI/Commands/Files/DeleteAllFilesCommand.cs @@ -13,20 +13,12 @@ namespace Meadow.CLI.Commands.Files [Command("file delete all", Description = "Delete all files from the Meadow File System")] public class DeleteAllFilesCommand : MeadowSerialCommand { -#if WIN_10 - public IList Files { get; } -#else public IList Files { get; init; } -#endif #if USE_PARTITIONS [CommandOption("Partition", 'p', Description = "The partition to write to on the Meadow")] #endif -#if WIN_10 - public int Partition { get; } = 0; -#else public int Partition { get; init; } = 0; -#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/DeleteFileCommand.cs b/Meadow.CLI/Commands/Files/DeleteFileCommand.cs index f8d45a67..01264c09 100644 --- a/Meadow.CLI/Commands/Files/DeleteFileCommand.cs +++ b/Meadow.CLI/Commands/Files/DeleteFileCommand.cs @@ -17,20 +17,12 @@ public class DeleteFileCommand : MeadowSerialCommand 'f', Description = "The file(s) to delete from the Meadow Files System", IsRequired = true)] -#if WIN_10 - public IList Files { get; } -#else public IList Files { get; init; } -#endif #if USE_PARTITIONS [CommandOption("Partition", 'p', Description = "The partition to write to on the Meadow")] #endif -#if WIN_10 - public uint Partition { get; } = 0; -#else public uint Partition { get; init; } = 0; -#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/InitialFileBytesCommand.cs b/Meadow.CLI/Commands/Files/InitialFileBytesCommand.cs index fe183eb5..0eb39474 100644 --- a/Meadow.CLI/Commands/Files/InitialFileBytesCommand.cs +++ b/Meadow.CLI/Commands/Files/InitialFileBytesCommand.cs @@ -13,22 +13,14 @@ public class InitialFileBytesCommand : MeadowSerialCommand #if USE_PARTITIONS [CommandOption("Partition", 'p', Description = "The partition to list the files")] #endif -#if WIN_10 - public uint Partition { get; } = 0; -#else public uint Partition { get; init; } = 0; -#endif [CommandOption( "file", 'f', Description = "The file to get the bytes from", IsRequired = true)] -#if WIN_10 - public string Filename { get; } -#else public string Filename { get; init; } -#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/ListFilesCommand.cs b/Meadow.CLI/Commands/Files/ListFilesCommand.cs index 8e2931b2..27b60778 100644 --- a/Meadow.CLI/Commands/Files/ListFilesCommand.cs +++ b/Meadow.CLI/Commands/Files/ListFilesCommand.cs @@ -17,18 +17,10 @@ public class ListFilesCommand : MeadowSerialCommand #endif public const int FileSystemBlockSize = 4096; -#if WIN_10 - public int Partition { get; } = 0; -#else public int Partition { get; init; } = 0; -#endif [CommandOption("includeCrcs", 'i', Description = "Include the CRCs of the files")] -#if WIN_10 - public bool IncludeCrcs { get; } -#else public bool IncludeCrcs { get; init; } -#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Files/WriteFileCommand.cs b/Meadow.CLI/Commands/Files/WriteFileCommand.cs index 873a9581..a7726ceb 100644 --- a/Meadow.CLI/Commands/Files/WriteFileCommand.cs +++ b/Meadow.CLI/Commands/Files/WriteFileCommand.cs @@ -19,30 +19,18 @@ public class WritesFileCommand : MeadowSerialCommand 'f', Description = "The file(s) to write to the Meadow Files System", IsRequired = true)] -#if WIN_10 - public IList Files { get; } -#else public IList Files { get; init; } -#endif [CommandOption( "targetFiles", 't', Description = "The filename(s) to use on the Meadow File System")] -#if WIN_10 - public IList TargetFileNames { get; } = Array.Empty(); -#else public IList TargetFileNames { get; init; } = Array.Empty(); -#endif #if USE_PARTITIONS [CommandOption("Partition", 'p', Description = "The partition to write to on the Meadow")] #endif -#if WIN_10 - public int Partition { get; } = 0; -#else public int Partition { get; init; } = 0; -#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/MeadowCommand.cs b/Meadow.CLI/Commands/MeadowCommand.cs index 97121790..7b8c44f6 100644 --- a/Meadow.CLI/Commands/MeadowCommand.cs +++ b/Meadow.CLI/Commands/MeadowCommand.cs @@ -21,11 +21,7 @@ private protected MeadowCommand(DownloadManager downloadManager, ILoggerFactory } [CommandOption("LogVerbosity", 'g', Description = "Log verbosity")] -#if WIN_10 - public string[] Verbosity { get; } -#else public string[] Verbosity { get; init; } -#endif public virtual async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Mono/MonoDisableCommand.cs b/Meadow.CLI/Commands/Mono/MonoDisableCommand.cs index 663f6f0d..41c530d6 100644 --- a/Meadow.CLI/Commands/Mono/MonoDisableCommand.cs +++ b/Meadow.CLI/Commands/Mono/MonoDisableCommand.cs @@ -19,12 +19,7 @@ public MonoDisableCommand(DownloadManager downloadManager, ILoggerFactory logger } [CommandOption("force",'f', Description = "Send the Mono Disable Command even if Mono is already disabled")] -#if WIN_10 - public bool Force { get; } -#else public bool Force { get; init; } -#endif - public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Mono/MonoEnableCommand.cs b/Meadow.CLI/Commands/Mono/MonoEnableCommand.cs index 39c6ce02..0ce39fdd 100644 --- a/Meadow.CLI/Commands/Mono/MonoEnableCommand.cs +++ b/Meadow.CLI/Commands/Mono/MonoEnableCommand.cs @@ -19,11 +19,7 @@ public MonoEnableCommand(DownloadManager downloadManager, ILoggerFactory loggerF } [CommandOption("force",'f', Description = "Send the Mono Enable Command even if Mono is already enabled")] -#if WIN_10 - public bool Force { get; } -#else public bool Force { get; init; } -#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Mono/MonoUpdateRuntimeCommand.cs b/Meadow.CLI/Commands/Mono/MonoUpdateRuntimeCommand.cs index 64910c79..d6434373 100644 --- a/Meadow.CLI/Commands/Mono/MonoUpdateRuntimeCommand.cs +++ b/Meadow.CLI/Commands/Mono/MonoUpdateRuntimeCommand.cs @@ -11,18 +11,10 @@ namespace Meadow.CLI.Commands.Mono public class MonoUpdateRuntimeCommand : MeadowSerialCommand { [CommandOption("filename",'f', Description = "The local name of the mono runtime file - Default is empty")] -#if WIN_10 - public string Filename { get; } -#else public string Filename {get; init;} -#endif [CommandOption("osVersion", 'v', Description = "Flash the mono runtime from a specific downloaded OS version - x.x.x.x")] -#if WIN_10 - public string OSVersion { get; } -#else public string OSVersion { get; init; } -#endif private readonly ILogger _logger; diff --git a/Meadow.CLI/Commands/Qspi/QspiInitCommand.cs b/Meadow.CLI/Commands/Qspi/QspiInitCommand.cs index dc23a0e1..e3bdbc0e 100644 --- a/Meadow.CLI/Commands/Qspi/QspiInitCommand.cs +++ b/Meadow.CLI/Commands/Qspi/QspiInitCommand.cs @@ -13,11 +13,7 @@ public class QspiInitCommand : MeadowSerialCommand private readonly ILogger _logger; [CommandOption("value",'v', Description = "The QSPI Value to initialize", IsRequired = true)] -#if WIN_10 - public int Value { get; } -#else public int Value {get; init;} -#endif public QspiInitCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/Qspi/QspiReadCommand.cs b/Meadow.CLI/Commands/Qspi/QspiReadCommand.cs index 13b0aa05..f4414d68 100644 --- a/Meadow.CLI/Commands/Qspi/QspiReadCommand.cs +++ b/Meadow.CLI/Commands/Qspi/QspiReadCommand.cs @@ -13,11 +13,7 @@ public class QspiReadCommand : MeadowSerialCommand private readonly ILogger _logger; [CommandOption("value",'v', Description = "The QSPI Value to read", IsRequired = true)] -#if WIN_10 - public int Value { get; } -#else public int Value {get; init;} -#endif public QspiReadCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs b/Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs index e10ea4f4..0904e57f 100644 --- a/Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs +++ b/Meadow.CLI/Commands/Qspi/QspiWriteCommand.cs @@ -13,11 +13,7 @@ public class QspiWriteCommand : MeadowSerialCommand private readonly ILogger _logger; [CommandOption("value",'v', Description = "The QSPI Value to write", IsRequired = true)] -#if WIN_10 - public int Value { get; } -#else public int Value {get; init;} -#endif public QspiWriteCommand(DownloadManager downloadManager, ILoggerFactory loggerFactory, MeadowDeviceManager meadowDeviceManager) : base(downloadManager, loggerFactory, meadowDeviceManager) diff --git a/Meadow.CLI/Commands/Trace/TraceEnableCommand.cs b/Meadow.CLI/Commands/Trace/TraceEnableCommand.cs index 3f97646a..6593eb46 100644 --- a/Meadow.CLI/Commands/Trace/TraceEnableCommand.cs +++ b/Meadow.CLI/Commands/Trace/TraceEnableCommand.cs @@ -19,11 +19,7 @@ public TraceEnableCommand(DownloadManager downloadManager, ILoggerFactory logger } [CommandOption("Level", 'l', Description = "The desired trace level")] -#if WIN_10 - public uint? TraceLevel { get; } -#else public uint? TraceLevel { get; init; } -#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Trace/TraceLevelCommand.cs b/Meadow.CLI/Commands/Trace/TraceLevelCommand.cs index fe8b43fd..2de264bb 100644 --- a/Meadow.CLI/Commands/Trace/TraceLevelCommand.cs +++ b/Meadow.CLI/Commands/Trace/TraceLevelCommand.cs @@ -19,11 +19,7 @@ public TraceLevelCommand(DownloadManager downloadManager, ILoggerFactory loggerF } [CommandOption("TraceLevel",'t', Description = "The desired trace level")] -#if WIN_10 - public uint TraceLevel { get; } -#else public uint TraceLevel { get; init; } -#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Utility/DebugCommand.cs b/Meadow.CLI/Commands/Utility/DebugCommand.cs index a601d9f3..818787c0 100644 --- a/Meadow.CLI/Commands/Utility/DebugCommand.cs +++ b/Meadow.CLI/Commands/Utility/DebugCommand.cs @@ -22,11 +22,7 @@ public DebugCommand(DownloadManager downloadManager, ILoggerFactory loggerFactor // VS 2017 - 4022 // VS 2015 - 4020 [CommandOption("DebugPort", 'p', Description = "The port to run the debug server on")] -#if WIN_10 - public int Port { get; } = 4024; -#else public int Port { get; init; } = 4024; -#endif public override async ValueTask ExecuteAsync(IConsole console) { diff --git a/Meadow.CLI/Commands/Utility/DownloadOsCommand.cs b/Meadow.CLI/Commands/Utility/DownloadOsCommand.cs index b5d08eee..6067ee45 100644 --- a/Meadow.CLI/Commands/Utility/DownloadOsCommand.cs +++ b/Meadow.CLI/Commands/Utility/DownloadOsCommand.cs @@ -14,18 +14,10 @@ public DownloadOsCommand(DownloadManager downloadManager, ILoggerFactory loggerF } [CommandOption("force", 'f', Description = "Force re-download of the OS", IsRequired = false)] -#if WIN_10 - public bool Force { get; } = false; -#else public bool Force { get; init; } = false; -#endif [CommandOption("osVersion", 'v', Description = "Download a specific OS version - x.x.x.x", IsRequired = false)] -#if WIN_10 - public string OsVersion { get; } -#else public string OsVersion { get; init; } -#endif public override async ValueTask ExecuteAsync(IConsole console) { From 7f5ad7f5704c3a3e938cd7707016202af1b3f575 Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Wed, 16 Aug 2023 12:41:32 +0100 Subject: [PATCH 10/11] Use the existing 6.0 HCOM csproj. --- Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj | 2 +- MeadowCLI.Classic.sln | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj index 4e25b2d6..f538bb88 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj @@ -79,6 +79,6 @@ - + diff --git a/MeadowCLI.Classic.sln b/MeadowCLI.Classic.sln index 493d515a..db2232d9 100644 --- a/MeadowCLI.Classic.sln +++ b/MeadowCLI.Classic.sln @@ -7,7 +7,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Core.Classic", " EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.CLI.Classic", "Meadow.CLI\Meadow.CLI.Classic.csproj", "{C1ADC097-F805-4A35-9706-DF243D22E31E}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Hcom.Classic", "Meadow.Hcom\Meadow.Hcom.Classic.csproj", "{3918812D-B2C2-416D-8A64-10FD2B932852}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Meadow.Hcom.6.0.0", "Meadow.Hcom\Meadow.Hcom.6.0.0.csproj", "{4CC9DB50-2CDA-41ED-B50E-3919243C4EC1}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -23,10 +23,10 @@ Global {C1ADC097-F805-4A35-9706-DF243D22E31E}.Debug|Any CPU.Build.0 = Debug|Any CPU {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.ActiveCfg = Release|Any CPU {C1ADC097-F805-4A35-9706-DF243D22E31E}.Release|Any CPU.Build.0 = Release|Any CPU - {3918812D-B2C2-416D-8A64-10FD2B932852}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {3918812D-B2C2-416D-8A64-10FD2B932852}.Debug|Any CPU.Build.0 = Debug|Any CPU - {3918812D-B2C2-416D-8A64-10FD2B932852}.Release|Any CPU.ActiveCfg = Release|Any CPU - {3918812D-B2C2-416D-8A64-10FD2B932852}.Release|Any CPU.Build.0 = Release|Any CPU + {4CC9DB50-2CDA-41ED-B50E-3919243C4EC1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {4CC9DB50-2CDA-41ED-B50E-3919243C4EC1}.Debug|Any CPU.Build.0 = Debug|Any CPU + {4CC9DB50-2CDA-41ED-B50E-3919243C4EC1}.Release|Any CPU.ActiveCfg = Release|Any CPU + {4CC9DB50-2CDA-41ED-B50E-3919243C4EC1}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE From 20abd5a1a4209aad44993d1e6982e598759eef1e Mon Sep 17 00:00:00 2001 From: Dominique Louis Date: Thu, 24 Aug 2023 10:50:53 +0100 Subject: [PATCH 11/11] Bump csproj and CI version to 1.3.0.x --- .github/workflows/dotnet.yml | 6 +++--- Meadow.CLI.Core/Meadow.CLI.Core.6.0.0.csproj | 2 +- Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj | 2 +- Meadow.CLI.Core/Meadow.CLI.Core.VS2019.csproj | 2 +- Meadow.CLI.Core/Meadow.CLI.Core.csproj | 2 +- Meadow.CLI/Meadow.CLI.Classic.csproj | 2 +- Meadow.CLI/Meadow.CLI.csproj | 2 +- 7 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index faad9833..33b7b870 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -1,8 +1,8 @@ name: Meadow.CLI env: - CLI_RELEASE_VERSION: 1.2.0.0 - IDE_TOOLS_RELEASE_VERSION: 1.2.0 - MEADOW_OS_VERSION: 1.2.0.0 + CLI_RELEASE_VERSION: 1.3.0.0 + IDE_TOOLS_RELEASE_VERSION: 1.3.0 + MEADOW_OS_VERSION: 1.3.0.0 VS_MAC_2019_VERSION: 8.10 VS_MAC_2022_VERSION: 17.5 diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.6.0.0.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.6.0.0.csproj index c063a2ec..86877384 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.6.0.0.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.6.0.0.csproj @@ -11,7 +11,7 @@ preview enable True - 1.2.0.0 + 1.3.0.0 diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj index f538bb88..148a53d7 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.Classic.csproj @@ -11,7 +11,7 @@ preview enable True - 1.2.2.0 + 1.3.0.0 diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.VS2019.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.VS2019.csproj index 3912ddb2..c3999bd3 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.VS2019.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.VS2019.csproj @@ -11,7 +11,7 @@ preview enable True - 1.2.0.0 + 1.3.0.0 diff --git a/Meadow.CLI.Core/Meadow.CLI.Core.csproj b/Meadow.CLI.Core/Meadow.CLI.Core.csproj index 1cba4598..31e7c909 100644 --- a/Meadow.CLI.Core/Meadow.CLI.Core.csproj +++ b/Meadow.CLI.Core/Meadow.CLI.Core.csproj @@ -11,7 +11,7 @@ preview enable True - 1.2.0.0 + 1.3.0.0 diff --git a/Meadow.CLI/Meadow.CLI.Classic.csproj b/Meadow.CLI/Meadow.CLI.Classic.csproj index 0c30fd7b..a28ddb56 100644 --- a/Meadow.CLI/Meadow.CLI.Classic.csproj +++ b/Meadow.CLI/Meadow.CLI.Classic.csproj @@ -10,7 +10,7 @@ Peter Moody, Adrian Stevens, Brian Kim, Pete Garafano, Dominique Louis Wilderness Labs, Inc true - 1.2.2.0 + 1.3.0.0 AnyCPU http://developer.wildernesslabs.co/Meadow/Meadow.Foundation/ icon.png diff --git a/Meadow.CLI/Meadow.CLI.csproj b/Meadow.CLI/Meadow.CLI.csproj index ee1c6f48..19b98542 100644 --- a/Meadow.CLI/Meadow.CLI.csproj +++ b/Meadow.CLI/Meadow.CLI.csproj @@ -10,7 +10,7 @@ Peter Moody, Adrian Stevens, Brian Kim, Pete Garafano, Dominique Louis Wilderness Labs, Inc true - 1.2.0.0 + 1.3.0.0 AnyCPU http://developer.wildernesslabs.co/Meadow/Meadow.Foundation/ icon.png