diff options
-rw-r--r-- | docs/release-notes.md | 3 | ||||
-rw-r--r-- | src/SMAPI.Installer/InteractiveInstaller.cs | 16 | ||||
-rw-r--r-- | src/SMAPI.Installer/StardewModdingAPI.Installer.csproj | 3 | ||||
-rw-r--r-- | src/SMAPI.sln | 1 |
4 files changed, 17 insertions, 6 deletions
diff --git a/docs/release-notes.md b/docs/release-notes.md index dc88bfa4..18946a4f 100644 --- a/docs/release-notes.md +++ b/docs/release-notes.md @@ -20,6 +20,9 @@ * Fixed mods which implement `IAssetLoader` directly not being allowed to load files due to incorrect conflict detection. * Fixed SMAPI blocking reflection access to vanilla members on overridden types. +* For SMAPI developers: + * Added the SMAPI installer version and platform to the window title to simplify troubleshooting. + ## 2.0 ### Release highlights * **Mod update checks** diff --git a/src/SMAPI.Installer/InteractiveInstaller.cs b/src/SMAPI.Installer/InteractiveInstaller.cs index cbc8a401..2ac53229 100644 --- a/src/SMAPI.Installer/InteractiveInstaller.cs +++ b/src/SMAPI.Installer/InteractiveInstaller.cs @@ -7,6 +7,7 @@ using System.Reflection; using System.Threading; using Microsoft.Win32; using StardewModdingApi.Installer.Enums; +using StardewModdingAPI.Common; namespace StardewModdingApi.Installer { @@ -137,6 +138,13 @@ namespace StardewModdingApi.Installer public void Run(string[] args) { /**** + ** Get platform & set window title + ****/ + Platform platform = this.DetectPlatform(); + Console.Title = $"SMAPI {new SemanticVersionImpl(this.GetType().Assembly.GetName().Version)} installer on {platform}"; + Console.WriteLine(); + + /**** ** read command-line arguments ****/ // get action from CLI @@ -160,10 +168,6 @@ namespace StardewModdingApi.Installer /**** ** collect details ****/ - // get platform - Platform platform = this.DetectPlatform(); - this.PrintDebug($"Platform: {(platform == Platform.Windows ? "Windows" : "Linux or Mac")}."); - // get game path DirectoryInfo installDir = this.InteractivelyGetInstallPath(platform, gamePathArg); if (installDir == null) @@ -183,7 +187,9 @@ namespace StardewModdingApi.Installer unixLauncher = Path.Combine(installDir.FullName, "StardewValley"), unixLauncherBackup = Path.Combine(installDir.FullName, "StardewValley-original") }; - this.PrintDebug($"Install path: {installDir}."); + + // show output + Console.WriteLine($"Your game folder: {installDir}."); /**** ** validate assumptions diff --git a/src/SMAPI.Installer/StardewModdingAPI.Installer.csproj b/src/SMAPI.Installer/StardewModdingAPI.Installer.csproj index f8e368a4..d3a6aa0b 100644 --- a/src/SMAPI.Installer/StardewModdingAPI.Installer.csproj +++ b/src/SMAPI.Installer/StardewModdingAPI.Installer.csproj @@ -1,4 +1,4 @@ -<?xml version="1.0" encoding="utf-8"?> +<?xml version="1.0" encoding="utf-8"?> <Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" /> <PropertyGroup> @@ -50,6 +50,7 @@ <CopyToOutputDirectory>Always</CopyToOutputDirectory> </Content> </ItemGroup> + <Import Project="..\SMAPI.Common\StardewModdingAPI.Common.projitems" Label="Shared" /> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <Import Project="..\..\build\common.targets" /> <Import Project="..\..\build\prepare-install-package.targets" /> diff --git a/src/SMAPI.sln b/src/SMAPI.sln index 1cb858bc..b42e39ce 100644 --- a/src/SMAPI.sln +++ b/src/SMAPI.sln @@ -52,6 +52,7 @@ EndProject Global GlobalSection(SharedMSBuildProjectFiles) = preSolution SMAPI.Common\StardewModdingAPI.Common.projitems*{2aa02fb6-ff03-41cf-a215-2ee60ab4f5dc}*SharedItemsImports = 13 + SMAPI.Common\StardewModdingAPI.Common.projitems*{443ddf81-6aaf-420a-a610-3459f37e5575}*SharedItemsImports = 4 SMAPI.Common\StardewModdingAPI.Common.projitems*{ea4f1e80-743f-4a1d-9757-ae66904a196a}*SharedItemsImports = 4 SMAPI.Common\StardewModdingAPI.Common.projitems*{f1a573b0-f436-472c-ae29-0b91ea6b9f8f}*SharedItemsImports = 4 EndGlobalSection |