1
0
mirror of https://github.com/mikf/gallery-dl.git synced 2024-11-22 10:42:34 +01:00
Commit Graph

9 Commits

Author SHA1 Message Date
Mike Fährmann
e03b99ba0e
[actions] emit logging messages before waiting/exiting/etc
distinguish between actions that should run before or after
a logging message gets emitted
2024-07-01 01:19:25 +02:00
Mike Fährmann
f7a6401031
[actions] move LoggerAdapter from 'output' to 'actions' 2024-06-30 20:41:51 +02:00
Mike Fährmann
f41a5065b2
[actions] support multiple actions per pattern 2024-06-30 02:36:33 +02:00
Mike Fährmann
8219a78b8d
[actions] extend 'wait'
allow specifying a duration like for --sleep
2024-06-29 23:58:38 +02:00
Mike Fährmann
84b3da54aa
[actions] add 'exec' action (#5619) 2024-06-29 23:02:48 +02:00
Mike Fährmann
c9860002ba
[actions] add 'abort' and 'terminate' actions (#5778) 2024-06-29 19:20:17 +02:00
Mike Fährmann
d80f4fbc10
[actions] optimize empty patterns 2024-06-29 18:57:48 +02:00
Mike Fährmann
92f98e6f5e
'sys.exit' -> 'SystemExit' 2023-08-21 23:46:39 +02:00
Mike Fährmann
4235d412c4
implement 'actions'
continuation of d37e7f48
but more versatile and extendable

Example:

"actions": [
    # change debug messages to info
    ["debug", "level ~info"],

    # change exit status to a non-zero value
    ["info:^No results for", "status |= 1"],

    # exit with status 2 on 429
    ["warning:429", "exit 2"],

    # restart extractor when no cookies found
    ["warning:^[Nn]o .*cookies", "restart"]
]
2023-03-10 22:08:10 +01:00