about summary refs log tree commit diff stats
path: root/cgitrc.5.txt
diff options
context:
space:
mode:
Diffstat (limited to 'cgitrc.5.txt')
-rw-r--r--cgitrc.5.txt34
1 files changed, 0 insertions, 34 deletions
diff --git a/cgitrc.5.txt b/cgitrc.5.txt index 45db6c7..7dd644a 100644 --- a/cgitrc.5.txt +++ b/cgitrc.5.txt
@@ -632,37 +632,6 @@ specification with the relevant string; available values are:
632'exec:':: 632'exec:'::
633 The default "one process per filter" mode. 633 The default "one process per filter" mode.
634 634
635'lua:'::
636 Executes the script using a built-in Lua interpreter. The script is
637 loaded once per execution of cgit, and may be called multiple times
638 during cgit's lifetime, making it a good choice for repeated filters
639 such as the 'email filter'. It responds to three functions:
640
641 'filter_open(argument1, argument2, argument3, ...)'::
642 This is called upon activation of the filter for a particular
643 set of data.
644 'filter_write(buffer)'::
645 This is called whenever cgit writes data to the webpage.
646 'filter_close()'::
647 This is called when the current filtering operation is
648 completed. It must return an integer value. Usually 0
649 indicates success.
650
651 Additionally, cgit exposes to the Lua the following built-in functions:
652
653 'html(str)'::
654 Writes 'str' to the webpage.
655 'html_txt(str)'::
656 HTML escapes and writes 'str' to the webpage.
657 'html_attr(str)'::
658 HTML escapes for an attribute and writes "str' to the webpage.
659 'html_url_path(str)'::
660 URL escapes for a path and writes 'str' to the webpage.
661 'html_url_arg(str)'::
662 URL escapes for an argument and writes 'str' to the webpage.
663 'html_include(file)'::
664 Includes 'file' in webpage.
665
666 635
667Parameters are provided to filters as follows. 636Parameters are provided to filters as follows.
668 637
@@ -696,9 +665,6 @@ auth filter::
696 with a 302 redirect, and write to output one or more "Set-Cookie" 665 with a 302 redirect, and write to output one or more "Set-Cookie"
697 HTTP headers, each followed by a newline. 666 HTTP headers, each followed by a newline.
698 667
699 Please see `filters/simple-authentication.lua` for a clear example
700 script that may be modified.
701
702commit filter:: 668commit filter::
703 This filter is given no arguments. The commit message text that is to 669 This filter is given no arguments. The commit message text that is to
704 be filtered is available on standard input and the filtered text is 670 be filtered is available on standard input and the filtered text is