From 27e09d80ef3fbe46cb8c1bf5b7a7edda2e7cf82b Mon Sep 17 00:00:00 2001 From: Jesse Bannon Date: Thu, 26 Sep 2024 18:51:14 -0700 Subject: [PATCH] deprecation notice --- docs/source/deprecation_notices.rst | 39 +++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/docs/source/deprecation_notices.rst b/docs/source/deprecation_notices.rst index 29e3c5b0..687b33f9 100644 --- a/docs/source/deprecation_notices.rst +++ b/docs/source/deprecation_notices.rst @@ -1,6 +1,45 @@ Deprecation Notices =================== +Sep 2024 +-------- + +regex plugin +~~~~~~~~~~~~ +Regex plugin has been removed in favor of scripting. The function +:ref:`config_reference/scripting/scripting_functions:regex_capture_many` +has been created to replicate the plugin's behavior. See the following converted example: + +.. code-block:: yaml + :caption: regex plugin + + regex: + from: + title: + match: + - ".*? - (.*)" # Captures 'Some - Song' from 'Emily Hopkins - Some - Song' + capture_group_names: + - "captured_track_title" + capture_group_defaults: + - "{title}" + overrides: + track_title: "{captured_track_title}" + +.. code-block:: yaml + :caption: regex plugin + + overrides: + # Captures 'Some - Song' from 'Emily Hopkins - Some - Song' + captured_track_title: >- + { + %regex_capture_many( + title, + [ ".*? - (.*)" ], + [ title ] + ) + } + track_title: "{%array_at(captured_track_title, 1)}" + Oct 2023 --------