Unverified Commit c8c1423c authored by github-actions[bot]'s avatar github-actions[bot] Committed by GitHub
Browse files

Merge master into staging-next

parents 40af042f 55544a3f
Loading
Loading
Loading
Loading
+61 −26
Original line number Diff line number Diff line
@@ -3,8 +3,11 @@
with lib;

let

  cfg = config.services.networkd-dispatcher;

in {

  options = {
    services.networkd-dispatcher = {

@@ -14,15 +17,50 @@ in {
        for usage.
      '');

      scriptDir = mkOption {
        type = types.path;
        default = "/var/lib/networkd-dispatcher";
        description = mdDoc ''
          This directory is used for keeping various scripts read and run by
          networkd-dispatcher. See [https://gitlab.com/craftyguy/networkd-dispatcher](upstream instructions)
          for directory structure and script usage.
      rules = mkOption {
        default = {};
        example = lib.literalExpression ''
          { "restart-tor" = {
              onState = ["routable" "off"];
              script = '''
                #!''${pkgs.runtimeShell}
                if [[ $IFACE == "wlan0" && $AdministrativeState == "configured" ]]; then
                  echo "Restarting Tor ..."
                  systemctl restart tor
                fi
                exit 0
              ''';
            };
          };
        '';
        description = lib.mdDoc ''
          Declarative configuration of networkd-dispatcher rules. See
          [https://gitlab.com/craftyguy/networkd-dispatcher](upstream instructions)
          for an introduction and example scripts.
        '';
        type = types.attrsOf (types.submodule {
          options = {
            onState = mkOption {
              type = types.listOf (types.enum [
                "routable" "dormant" "no-carrier" "off" "carrier" "degraded"
                "configuring" "configured"
              ]);
              default = null;
              description = lib.mdDoc ''
                List of names of the systemd-networkd operational states which
                should trigger the script. See <https://www.freedesktop.org/software/systemd/man/networkctl.html>
                for a description of the specific state type.
              '';
            };
            script = mkOption {
              type = types.lines;
              description = lib.mdDoc ''
                Shell commands executed on specified operational states.
              '';
            };
          };
        });
      };

    };
  };
@@ -30,34 +68,31 @@ in {
  config = mkIf cfg.enable {

    systemd = {

      packages = [ pkgs.networkd-dispatcher ];
      services.networkd-dispatcher = {
        wantedBy = [ "multi-user.target" ];
        # Override existing ExecStart definition
        serviceConfig.ExecStart = [
        serviceConfig.ExecStart = let
          scriptDir = pkgs.symlinkJoin {
            name = "networkd-dispatcher-script-dir";
            paths = lib.mapAttrsToList (name: cfg:
              (map(state:
                pkgs.writeTextFile {
                  inherit name;
                  text = cfg.script;
                  destination = "/${state}.d/${name}";
                  executable = true;
                }
              ) cfg.onState)
            ) cfg.rules;
          };
        in [
          ""
          "${pkgs.networkd-dispatcher}/bin/networkd-dispatcher -v --script-dir ${cfg.scriptDir} $networkd_dispatcher_args"
          "${pkgs.networkd-dispatcher}/bin/networkd-dispatcher -v --script-dir ${scriptDir} $networkd_dispatcher_args"
        ];
      };

      # Directory structure required according to upstream instructions
      # https://gitlab.com/craftyguy/networkd-dispatcher
      tmpfiles.rules = [
        "d '${cfg.scriptDir}'               0750 root root - -"
        "d '${cfg.scriptDir}/routable.d'    0750 root root - -"
        "d '${cfg.scriptDir}/dormant.d'     0750 root root - -"
        "d '${cfg.scriptDir}/no-carrier.d'  0750 root root - -"
        "d '${cfg.scriptDir}/off.d'         0750 root root - -"
        "d '${cfg.scriptDir}/carrier.d'     0750 root root - -"
        "d '${cfg.scriptDir}/degraded.d'    0750 root root - -"
        "d '${cfg.scriptDir}/configuring.d' 0750 root root - -"
        "d '${cfg.scriptDir}/configured.d'  0750 root root - -"
      ];

    };


  };
}
+3 −3
Original line number Diff line number Diff line
@@ -2,7 +2,7 @@

let
  pname = "erigon";
  version = "2.39.0";
  version = "2.40.1";
in
buildGoModule {
  inherit pname version;
@@ -11,11 +11,11 @@ buildGoModule {
    owner = "ledgerwatch";
    repo = pname;
    rev = "v${version}";
    sha256 = "sha256-HlAnuc6n/de6EzHTit3xGCFLrc2+S+H/o0gCxH8d0aU=";
    sha256 = "sha256-iuJ/iajZiqKBP4hgrwt8KKkWEdYa+idpai/aWpCOjQw=";
    fetchSubmodules = true;
  };

  vendorSha256 = "sha256-kKwaA6NjRdg97tTEzEI+TWMSx7izzFWcefR5B086cUY=";
  vendorSha256 = "sha256-0xHu7uvk7kRxyLXGvrT9U8vgfZPrs7Rmg2lFH49YOSI=";
  proxyVendor = true;

  # Build errors in mdbx when format hardening is enabled:
+2 −2
Original line number Diff line number Diff line
@@ -1442,8 +1442,8 @@ let
        mktplcRef = {
          name = "Ionide-fsharp";
          publisher = "Ionide";
          version = "6.0.5";
          sha256 = "sha256-vlmLr/1rBreqZifzEwAlhyGzHG28oZa+kmMzRl53tOI=";
          version = "7.5.1";
          sha256 = "sha256-AiDYqYF+F69O/aeolIEzqLmg20YN/I4EV6XMa8UgMns=";
        };
        meta = with lib; {
          changelog = "https://marketplace.visualstudio.com/items/Ionide.Ionide-fsharp/changelog";
+0 −23
Original line number Diff line number Diff line
diff --git a/Ryujinx.Common/ReleaseInformations.cs b/Ryujinx.Common/ReleaseInformations.cs
index 35890406..cca77163 100644
--- a/Ryujinx.Common/ReleaseInformations.cs
+++ b/Ryujinx.Common/ReleaseInformations.cs
@@ -42,12 +42,14 @@ namespace Ryujinx.Common

         public static string GetBaseApplicationDirectory()
         {
-            if (IsFlatHubBuild())
-            {
+            //if (IsFlatHubBuild())
+            //{
+                // This needs to be a mutable path, while CurrentDomain.BaseDirectory refers to the nix store.
+                // AppDataManager.BaseDirPath refers to ".config/Ryujinx" on Linux.
                 return AppDataManager.BaseDirPath;
-            }
+            //}
 
-            return AppDomain.CurrentDomain.BaseDirectory;
+            //return AppDomain.CurrentDomain.BaseDirectory;
         }
     }
 }
+8 −12
Original line number Diff line number Diff line
@@ -29,13 +29,13 @@

buildDotnetModule rec {
  pname = "ryujinx";
  version = "1.1.489"; # Based off of the official github actions builds: https://github.com/Ryujinx/Ryujinx/actions/workflows/release.yml
  version = "1.1.650"; # Based off of the official github actions builds: https://github.com/Ryujinx/Ryujinx/actions/workflows/release.yml

  src = fetchFromGitHub {
    owner = "Ryujinx";
    repo = "Ryujinx";
    rev = "37d27c4c99486312d9a282d7fc056c657efe0848";
    sha256 = "0h55vv2g9i81km0jzlb62arlky5ci4i45jyxig3znqr1zb4l0a67";
    rev = "b8556530f2b160db70ff571adf25ae26d4b8f58f";
    sha256 = "098yx4nwmkbab595a2xq9f5libzvsj01f3wf83nsbgzndy1h85ja";
  };

  dotnet-sdk = dotnetCorePackages.sdk_7_0;
@@ -79,16 +79,12 @@ buildDotnetModule rec {
    SDL2
  ];

  patches = [
    ./appdir.patch # Ryujinx attempts to write to the nix store. This patch redirects it to "~/.config/Ryujinx" on Linux.
  ];

  projectFile = "Ryujinx.sln";
  testProjectFile = "Ryujinx.Tests/Ryujinx.Tests.csproj";
  doCheck = true;

  dotnetFlags = [
    "/p:ExtraDefineConstants=DISABLE_UPDATER"
    "/p:ExtraDefineConstants=DISABLE_UPDATER%2CFORCE_EXTERNAL_BASE_DIR"
  ];

  executables = [
@@ -113,11 +109,11 @@ buildDotnetModule rec {
    mkdir -p $out/share/{applications,icons/hicolor/scalable/apps,mime/packages}
    pushd ${src}/distribution/linux

    install -D ./ryujinx.desktop $out/share/applications/ryujinx.desktop
    install -D ./ryujinx-mime.xml $out/share/mime/packages/ryujinx-mime.xml
    install -D ./ryujinx-logo.svg $out/share/icons/hicolor/scalable/apps/ryujinx.svg
    install -D ./Ryujinx.desktop $out/share/applications/Ryujinx.desktop
    install -D ./mime/Ryujinx.xml $out/share/mime/packages/Ryujinx.xml
    install -D ../misc/Logo.svg $out/share/icons/hicolor/scalable/apps/Ryujinx.svg

    substituteInPlace $out/share/applications/ryujinx.desktop \
    substituteInPlace $out/share/applications/Ryujinx.desktop \
      --replace "Exec=Ryujinx" "Exec=$out/bin/Ryujinx"

    ln -s $out/bin/Ryujinx $out/bin/ryujinx
Loading