From 3bba58d4ac605f27d06cd674412f8f1cd56c6245 Mon Sep 17 00:00:00 2001 From: redxef Date: Tue, 17 Dec 2024 23:33:36 +0100 Subject: [PATCH] docs: move definition listing to lisp.md. --- README.md | 13 ------------- lisp.md | 15 +++++++++++++++ 2 files changed, 15 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index c4e1940..8855aee 100644 --- a/README.md +++ b/README.md @@ -121,19 +121,6 @@ the items by name you could use the following program: items) ``` -#### Available definitions - -- **lower**: lowercases a string (`(eq (lower "SomeString") "somestring")`) -- **is-genre**: check if the item is of this genre, partial matches - allowed, the example filter would match the genre "Nu-Metal" (`(is-genre "metal" (genre-list))`) -- **is-genre-exact**: the same as `is-genre`, but does not match paritally -- **is-favorite**: matches a favorite item (`(is-favorite)`) -- **is-type**: matches the type of item look at - [BaseItemKind.cs](https://github.com/jellyfin/jellyfin/blob/master/Jellyfin.Data/Enums/BaseItemKind.cs) - for a list of items. The plugin has enabled support for `Audio, MusicAlbum, Playlist` (`(is-type "Audio")`) -- **log[diwe]**: write to the logger with the respective levels (`debug`, `information`, `warning`, `error`). - Takes the same arguments as `Logger.LogInformation(...)`. - ### Filename The path to this file, only used internally and updated by the program. diff --git a/lisp.md b/lisp.md index 30e91a9..9421afa 100644 --- a/lisp.md +++ b/lisp.md @@ -112,3 +112,18 @@ between `0` (inclusive) and `n` (exclusive). If two arguments are given it gives a integer between `a` (inclusive) and `b` (exclusive). **shuf**: same as **shuffle**. + +## Pre-defined convenience functions + +- **lower**: lowercases a string (`(eq (lower "SomeString") "somestring")`) +- **is-genre**: check if the item is of this genre, partial matches + allowed, the example filter would match the genre "Nu-Metal" (`(is-genre "metal" (genre-list))`) +- **is-genre-exact**: the same as `is-genre`, but does not match paritally +- **is-favorite**: matches a favorite item (`(is-favorite)`) +- **is-type**: matches the type of item look at + [BaseItemKind.cs](https://github.com/jellyfin/jellyfin/blob/master/Jellyfin.Data/Enums/BaseItemKind.cs) + for a list of items. The plugin has enabled support for `Audio, MusicAlbum, Playlist` (`(is-type "Audio")`) +- **logd**, **logi**, **logw**, **loge**: write to the logger with the respective levels (`debug`, `information`, `warning`, `error`). + Takes the same arguments as `Logger.LogInformation(...)`. + +And many more.