From d4d03303666496ba54eaedc2ea06924b9c3f0a71 Mon Sep 17 00:00:00 2001 From: Finn Behrens Date: Tue, 7 Dec 2021 09:21:29 +0100 Subject: [PATCH] pleroma: fix build with elixir 1.13 --- .../0001-move-result-into-with-guard.patch | 26 +++++++++++++++++++ pkgs/servers/pleroma/default.nix | 2 ++ 2 files changed, 28 insertions(+) create mode 100644 pkgs/servers/pleroma/0001-move-result-into-with-guard.patch diff --git a/pkgs/servers/pleroma/0001-move-result-into-with-guard.patch b/pkgs/servers/pleroma/0001-move-result-into-with-guard.patch new file mode 100644 index 000000000000..07b224b1f0da --- /dev/null +++ b/pkgs/servers/pleroma/0001-move-result-into-with-guard.patch @@ -0,0 +1,26 @@ +From 8af53101fbeb0d4855ffa2b33069e833abf2e825 Mon Sep 17 00:00:00 2001 +From: Finn Behrens +Date: Tue, 7 Dec 2021 09:18:53 +0100 +Subject: [PATCH] move result into with guard + +--- + lib/pleroma/web/activity_pub/publisher.ex | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +diff --git a/lib/pleroma/web/activity_pub/publisher.ex b/lib/pleroma/web/activity_pub/publisher.ex +index 4f29a44..849b359 100644 +--- a/lib/pleroma/web/activity_pub/publisher.ex ++++ b/lib/pleroma/web/activity_pub/publisher.ex +@@ -63,8 +63,7 @@ def publish_one(%{inbox: inbox, json: json, actor: %User{} = actor, id: id} = pa + date: date + }) + +- with {:ok, %{status: code}} when code in 200..299 <- +- result = ++ with {:ok, %{status: code}} = result when code in 200..299 <- + HTTP.post( + inbox, + json, +-- +2.34.0 + diff --git a/pkgs/servers/pleroma/default.nix b/pkgs/servers/pleroma/default.nix index f8092419215d..5509236c7664 100644 --- a/pkgs/servers/pleroma/default.nix +++ b/pkgs/servers/pleroma/default.nix @@ -17,6 +17,8 @@ beamPackages.mixRelease rec { sha256 = "sha256-XYZIf8/Vznl4FvVAOy5GVfTBTCwhfUol/3vWWIDwIxQ="; }; + patches = [ ./0001-move-result-into-with-guard.patch ]; + mixNixDeps = import ./mix.nix { inherit beamPackages lib; overrides = (final: prev: {