diff --git a/docs/configuration.rst b/docs/configuration.rst index 373f9f41..47c50d2f 100644 --- a/docs/configuration.rst +++ b/docs/configuration.rst @@ -984,6 +984,8 @@ Description | Can be one of ``debug``, ``info``, ``warning``, ``error`` or an integer value. ``print`` Write argument to stdout. + ``exec`` + Run a shell command. ``abort``: Stop the current extractor run. ``terminate``: diff --git a/gallery_dl/actions.py b/gallery_dl/actions.py index 8362c744..1d18e3a3 100644 --- a/gallery_dl/actions.py +++ b/gallery_dl/actions.py @@ -80,6 +80,12 @@ def action_level(opts): return _level +def action_exec(opts): + def _exec(_): + util.Popen(opts, shell=True).wait() + return _exec + + def action_wait(opts): def _wait(args): input("Press Enter to continue") @@ -110,12 +116,13 @@ def action_exit(opts): ACTIONS = { + "abort" : action_abort, + "exec" : action_exec, + "exit" : action_exit, + "level" : action_level, "print" : action_print, + "restart" : action_restart, "status" : action_status, - "level" : action_level, - "abort" : action_abort, "terminate": action_terminate, - "restart" : action_restart, "wait" : action_wait, - "exit" : action_exit, } diff --git a/gallery_dl/version.py b/gallery_dl/version.py index a8ff38ea..e1a68602 100644 --- a/gallery_dl/version.py +++ b/gallery_dl/version.py @@ -6,5 +6,5 @@ # it under the terms of the GNU General Public License version 2 as # published by the Free Software Foundation. -__version__ = "1.27.1" +__version__ = "1.27.2-dev" __variant__ = None