From fb510ea86be5ceb9e91573890242581fdbd77ad8 Mon Sep 17 00:00:00 2001 From: Rodrigo Arias Mallo Date: Sun, 28 Sep 2025 20:26:15 +0200 Subject: Initial version --- 199/index.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 199/index.md (limited to '199/index.md') diff --git a/199/index.md b/199/index.md new file mode 100644 index 0000000..92f6990 --- /dev/null +++ b/199/index.md @@ -0,0 +1,14 @@ +Title: Allow actions to be defined to handle URLs +Author: rodarima +Created: Fri, 14 Jun 2024 20:32:45 +0000 +State: closed + +Implements the logic to read rules from ~/.dillo/rulesrc which define custom actions to handle a URL. Here is an example: + + action "Open with MPV" shell "mpv $url" + action "Open with MPV (only audio)" shell "mpv --no-video $url" + action "Open with Firefox" shell "firefox $url" + +The standard input and output is still redirected to the same file descriptor as Dillo. + +The commands are spawned in a forked process using the system() call, which uses the shell to expand any variable. In particular, the $url variable is set to the current URL being opened. \ No newline at end of file -- cgit v1.2.3