diff --git a/minet/cli/url_parse/__init__.py b/minet/cli/url_parse/__init__.py index 9ab6815974..596a18359b 100644 --- a/minet/cli/url_parse/__init__.py +++ b/minet/cli/url_parse/__init__.py @@ -224,5 +224,10 @@ def __call__(self, parser, cli_args, values, option_string=None): "help": "Whether to strip the hostname suffix when fingerprinting the url.", "action": "store_true", }, + { + "flag": "--plaftorm-aware", + "help": "Whether url parsing should know about some specififc platform such as Facebook, YouTube etc. into account when normalizing urls. Note that this is different than activating --facebook or --youtube.", + "action": "store_true", + }, ], ) diff --git a/minet/cli/url_parse/url_parse.py b/minet/cli/url_parse/url_parse.py index 0f11077b3b..f1657627fc 100644 --- a/minet/cli/url_parse/url_parse.py +++ b/minet/cli/url_parse/url_parse.py @@ -92,8 +92,13 @@ def extract_standard_addendum(cli_args, url): strip_irrelevant_subdomains=cli_args.strip_irrelevant_subdomains, strip_protocol=cli_args.strip_protocol, strip_trailing_slash=cli_args.strip_trailing_slash, + platform_aware=cli_args.platform_aware, + ), + fingerprint_url( + url, + strip_suffix=cli_args.strip_suffix, + platform_aware=cli_args.platform_aware, ), - fingerprint_url(url, strip_suffix=cli_args.strip_suffix), infer_redirection(url), get_domain_name(url), get_hostname(url),