From cbaa845f5d51fe61a46d1a57950aa76a0a976d3e Mon Sep 17 00:00:00 2001 From: RMED24 <81475204+RMED24@users.noreply.github.com> Date: Sat, 7 Jan 2023 08:06:13 +0000 Subject: Include a start.sh file with correct launch options (#4013) * Include reference to start.sh to be bundled * Add start.sh * Fix silly mistake I made on windows-x64 * ... I cannot read properly * Make same changes for avalonia csproj * Remove notice from start.sh Co-authored-by: Mary-nyan * Update Ryujinx/Ryujinx.csproj Co-authored-by: Mary-nyan * Update Ryujinx.Ava/Ryujinx.Ava.csproj Co-authored-by: Mary-nyan * Update distribution/linux/start.sh Co-authored-by: TSRBerry <20988865+TSRBerry@users.noreply.github.com> * Update distribution/linux/start.sh Co-authored-by: TSRBerry <20988865+TSRBerry@users.noreply.github.com> * Update Ryujinx.Ava/Ryujinx.Ava.csproj Co-authored-by: TSRBerry <20988865+TSRBerry@users.noreply.github.com> * Update Ryujinx.csproj * Update Ryujinx.Ava.csproj * Rename start.sh to Ryujinx.sh * Update Ryujinx.csproj * Update Ryujinx.Ava.csproj * Update Ryujinx.Ava.csproj * Update Ryujinx.Ava/Ryujinx.Ava.csproj Co-authored-by: TSRBerry <20988865+TSRBerry@users.noreply.github.com> * Add `GDK_BACKEND` variable * Update Ryujinx.Ava.csproj * Update Program.cs * Update Program.cs * Update Ryujinx.sh * Update Program.cs * linux: Register mime types on launch * Add DOTNET_EnableAlternateStackCheck=1 to desktop file * linux: Add exclusion for RegisterMimeTypes for flathub builds * Update logo path * Cleanup Ryujinx.sh * Fix typo in ReleaseInformation * gha: Fix permissions for linux release binaries * ava: Rename output assembly to Ryujinx * Update mime database after installing new types Wait until logging is available before registering mime types * Copy mime types to output directory Co-authored-by: Mary-nyan Co-authored-by: TSRBerry <20988865+TSRBerry@users.noreply.github.com> --- Ryujinx.Common/Logging/Targets/FileLogTarget.cs | 2 +- Ryujinx.Common/ReleaseInformation.cs | 53 +++++++++++++++++++++++++ Ryujinx.Common/ReleaseInformations.cs | 53 ------------------------- 3 files changed, 54 insertions(+), 54 deletions(-) create mode 100644 Ryujinx.Common/ReleaseInformation.cs delete mode 100644 Ryujinx.Common/ReleaseInformations.cs (limited to 'Ryujinx.Common') diff --git a/Ryujinx.Common/Logging/Targets/FileLogTarget.cs b/Ryujinx.Common/Logging/Targets/FileLogTarget.cs index 401fe91b..24dd6d17 100644 --- a/Ryujinx.Common/Logging/Targets/FileLogTarget.cs +++ b/Ryujinx.Common/Logging/Targets/FileLogTarget.cs @@ -29,7 +29,7 @@ namespace Ryujinx.Common.Logging files[i].Delete(); } - string version = ReleaseInformations.GetVersion(); + string version = ReleaseInformation.GetVersion(); // Get path for the current time path = Path.Combine(logDir.FullName, $"Ryujinx_{version}_{DateTime.Now.ToString("yyyy-MM-dd_HH-mm-ss")}.log"); diff --git a/Ryujinx.Common/ReleaseInformation.cs b/Ryujinx.Common/ReleaseInformation.cs new file mode 100644 index 00000000..d0e01328 --- /dev/null +++ b/Ryujinx.Common/ReleaseInformation.cs @@ -0,0 +1,53 @@ +using Ryujinx.Common.Configuration; +using System; +using System.Reflection; + +namespace Ryujinx.Common +{ + // DO NOT EDIT, filled by CI + public static class ReleaseInformation + { + private const string FlatHubChannelOwner = "flathub"; + + public static string BuildVersion = "%%RYUJINX_BUILD_VERSION%%"; + public static string BuildGitHash = "%%RYUJINX_BUILD_GIT_HASH%%"; + public static string ReleaseChannelName = "%%RYUJINX_TARGET_RELEASE_CHANNEL_NAME%%"; + public static string ReleaseChannelOwner = "%%RYUJINX_TARGET_RELEASE_CHANNEL_OWNER%%"; + public static string ReleaseChannelRepo = "%%RYUJINX_TARGET_RELEASE_CHANNEL_REPO%%"; + + public static bool IsValid() + { + return !BuildGitHash.StartsWith("%%") && + !ReleaseChannelName.StartsWith("%%") && + !ReleaseChannelOwner.StartsWith("%%") && + !ReleaseChannelRepo.StartsWith("%%"); + } + + public static bool IsFlatHubBuild() + { + return IsValid() && ReleaseChannelOwner.Equals(FlatHubChannelOwner); + } + + public static string GetVersion() + { + if (IsValid()) + { + return BuildVersion; + } + else + { + return Assembly.GetEntryAssembly().GetCustomAttribute().InformationalVersion; + } + } + + public static string GetBaseApplicationDirectory() + { + if (IsFlatHubBuild()) + { + return AppDataManager.BaseDirPath; + } + + return AppDomain.CurrentDomain.BaseDirectory; + } + } +} \ No newline at end of file diff --git a/Ryujinx.Common/ReleaseInformations.cs b/Ryujinx.Common/ReleaseInformations.cs deleted file mode 100644 index 35890406..00000000 --- a/Ryujinx.Common/ReleaseInformations.cs +++ /dev/null @@ -1,53 +0,0 @@ -using Ryujinx.Common.Configuration; -using System; -using System.Reflection; - -namespace Ryujinx.Common -{ - // DO NOT EDIT, filled by CI - public static class ReleaseInformations - { - private const string FlatHubChannelOwner = "flathub"; - - public static string BuildVersion = "%%RYUJINX_BUILD_VERSION%%"; - public static string BuildGitHash = "%%RYUJINX_BUILD_GIT_HASH%%"; - public static string ReleaseChannelName = "%%RYUJINX_TARGET_RELEASE_CHANNEL_NAME%%"; - public static string ReleaseChannelOwner = "%%RYUJINX_TARGET_RELEASE_CHANNEL_OWNER%%"; - public static string ReleaseChannelRepo = "%%RYUJINX_TARGET_RELEASE_CHANNEL_REPO%%"; - - public static bool IsValid() - { - return !BuildGitHash.StartsWith("%%") && - !ReleaseChannelName.StartsWith("%%") && - !ReleaseChannelOwner.StartsWith("%%") && - !ReleaseChannelRepo.StartsWith("%%"); - } - - public static bool IsFlatHubBuild() - { - return IsValid() && ReleaseChannelOwner.Equals(FlatHubChannelOwner); - } - - public static string GetVersion() - { - if (IsValid()) - { - return BuildVersion; - } - else - { - return Assembly.GetEntryAssembly().GetCustomAttribute().InformationalVersion; - } - } - - public static string GetBaseApplicationDirectory() - { - if (IsFlatHubBuild()) - { - return AppDataManager.BaseDirPath; - } - - return AppDomain.CurrentDomain.BaseDirectory; - } - } -} -- cgit v1.2.3