commit: d54950b3588d8fe53d3b39db2efd6f2501962180
parent: fb843ded2b35b7f9ea92d981617742338dd25d5c
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date: Fri, 1 Mar 2019 23:26:36 +0100
mix.deps: Change auto_linker to my branch
Diffstat:
4 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/lib/pleroma/formatter.ex b/lib/pleroma/formatter.ex
@@ -15,7 +15,9 @@ defmodule Pleroma.Formatter do
@auto_linker_config hashtag: true,
hashtag_handler: &Pleroma.Formatter.hashtag_handler/4,
mention: true,
- mention_handler: &Pleroma.Formatter.mention_handler/4
+ mention_handler: &Pleroma.Formatter.mention_handler/4,
+ phone: false,
+ extra_prefixes: Pleroma.Config.get([:uri_schemes, :valid_schemes])
def escape_mention_handler("@" <> nickname = mention, buffer, _, _) do
case User.get_cached_by_nickname(nickname) do
diff --git a/mix.exs b/mix.exs
@@ -99,9 +99,7 @@ defmodule Pleroma.Mixfile do
{:ex_syslogger, github: "slashmili/ex_syslogger", tag: "1.4.0"},
{:timex, "~> 3.5"},
{:ueberauth, "~> 0.4"},
- {:auto_linker,
- git: "https://git.pleroma.social/pleroma/auto_linker.git",
- ref: "90613b4bae875a3610c275b7056b61ffdd53210d"},
+ {:auto_linker, git: "https://hacktivis.me/git/auto_linker.git", branch: "lanodan/master"},
{:pleroma_job_queue, "~> 0.2.0"},
{:telemetry, "~> 0.3"},
{:prometheus_ex, "~> 3.0"},
diff --git a/mix.lock b/mix.lock
@@ -1,6 +1,6 @@
%{
"accept": {:hex, :accept, "0.3.5", "b33b127abca7cc948bbe6caa4c263369abf1347cfa9d8e699c6d214660f10cd1", [:rebar3], [], "hexpm"},
- "auto_linker": {:git, "https://git.pleroma.social/pleroma/auto_linker.git", "90613b4bae875a3610c275b7056b61ffdd53210d", [ref: "90613b4bae875a3610c275b7056b61ffdd53210d"]},
+ "auto_linker": {:git, "https://hacktivis.me/git/auto_linker.git", "45a252c6fa9071fabad1d23858a420e77af744b4", [branch: "lanodan/master"]},
"base64url": {:hex, :base64url, "0.0.1", "36a90125f5948e3afd7be97662a1504b934dd5dac78451ca6e9abf85a10286be", [:rebar], [], "hexpm"},
"bunt": {:hex, :bunt, "0.2.0", "951c6e801e8b1d2cbe58ebbd3e616a869061ddadcc4863d0a2182541acae9a38", [:mix], [], "hexpm"},
"cachex": {:hex, :cachex, "3.0.2", "1351caa4e26e29f7d7ec1d29b53d6013f0447630bbf382b4fb5d5bad0209f203", [:mix], [{:eternal, "~> 1.2", [hex: :eternal, repo: "hexpm", optional: false]}, {:unsafe, "~> 1.0", [hex: :unsafe, repo: "hexpm", optional: false]}], "hexpm"},
diff --git a/test/web/common_api/common_api_utils_test.exs b/test/web/common_api/common_api_utils_test.exs
@@ -123,14 +123,15 @@ defmodule Pleroma.Web.CommonAPI.UtilsTest do
{:ok, user} =
UserBuilder.insert(%{nickname: "user__test", ap_id: "http://foo.com/user__test"})
- text = "**hello world**\n\n*another @user__test and @user__test google.com paragraph*"
+ text =
+ "**hello world**\n\n*another @user__test and @user__test http://google.com paragraph*"
expected =
"<p><strong>hello world</strong></p>\n<p><em>another <span class=\"h-card\"><a data-user=\"#{
user.id
}\" class=\"u-url mention\" href=\"http://foo.com/user__test\">@<span>user__test</span></a></span> and <span class=\"h-card\"><a data-user=\"#{
user.id
- }\" class=\"u-url mention\" href=\"http://foo.com/user__test\">@<span>user__test</span></a></span> <a href=\"http://google.com\">google.com</a> paragraph</em></p>\n"
+ }\" class=\"u-url mention\" href=\"http://foo.com/user__test\">@<span>user__test</span></a></span> <a href=\"http://google.com\">http://google.com</a> paragraph</em></p>\n"
{output, _, _} = Utils.format_input(text, "text/markdown")