mirror of
https://github.com/aquasecurity/kube-hunter.git
synced 2026-05-06 09:18:36 +00:00
* added plugins submodule, created two hookspecs, one for adding arguments, one for running code after the argument parsing * implemented plugins application on main file, changed mechanism for argument parsing * changed previous parsing function to not create the ArgumentParser, and implemented it as a hook for the parsing mechanism * added pluggy to required deps * removed unecessary add_config import * fixed formatting using black * restored main link file from master * moved import of parser to right before the register call, to avoid circular imports * added tests for the plugins hooks * removed blank line space * black reformat
14 lines
205 B
Python
14 lines
205 B
Python
from kube_hunter.plugins import hookimpl
|
|
|
|
return_string = "return_string"
|
|
|
|
|
|
@hookimpl
|
|
def parser_add_arguments(parser):
|
|
return return_string
|
|
|
|
|
|
@hookimpl
|
|
def load_plugin(args):
|
|
return return_string
|