diff --git a/pipreqs/pipreqs.py b/pipreqs/pipreqs.py index 6caa83b..44698e9 100755 --- a/pipreqs/pipreqs.py +++ b/pipreqs/pipreqs.py @@ -169,7 +169,7 @@ def join(f): def init(args): - encoding = args.get('encoding') + encoding = args.get('--encoding') candidates = get_all_imports(args[''], encoding=encoding) candidates = get_pkg_names(candidates) logging.debug("Found imports: " + ", ".join(candidates))