MCPcopy Index your code
hub / github.com/archlinux/archinstall / _parse_args

Method _parse_args

archinstall/lib/args.py:656–680  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

654 return parser
655
656 def _parse_args(self) -> Arguments:
657 argparse_args = vars(self._parser.parse_args())
658 args: Arguments = Arguments(**argparse_args)
659
660 # amend the parameters (check internal consistency)
661 # Installation can't be silent if config is not passed
662 if args.config is None and args.config_url is None:
663 args.silent = False
664
665 if args.debug:
666 warn(f'Warning: --debug mode will write certain credentials to {logger.path}!')
667
668 if args.plugin:
669 load_plugin(args.plugin)
670
671 if args.plugin_url:
672 plugin_data = self._fetch_from_url(args.plugin_url)
673 plugin_path = self._write_plugin_to_temp_file(plugin_data)
674 load_plugin(plugin_path)
675
676 if args.creds_decryption_key is None:
677 if os.environ.get('ARCHINSTALL_CREDS_DECRYPTION_KEY'):
678 args.creds_decryption_key = os.environ.get('ARCHINSTALL_CREDS_DECRYPTION_KEY')
679
680 return args
681
682 def _parse_config(self) -> dict[str, Any]:
683 config: dict[str, Any] = {}

Callers 1

__init__Method · 0.95

Calls 6

_fetch_from_urlMethod · 0.95
warnFunction · 0.90
load_pluginFunction · 0.90
ArgumentsClass · 0.85
parse_argsMethod · 0.45

Tested by

no test coverage detected