From f98b63b6106bf8e38b098f256aa25e7455db02dd Mon Sep 17 00:00:00 2001 From: Bulat Khasanov Date: Sat, 4 Mar 2017 18:16:36 +0300 Subject: [PATCH] add sort_keys param to sort lockfile --- pipenv/cli.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pipenv/cli.py b/pipenv/cli.py index fc99edb7..5d28e52c 100644 --- a/pipenv/cli.py +++ b/pipenv/cli.py @@ -440,7 +440,7 @@ def do_lock(): # Write out lockfile. with open(project.lockfile_location, 'w') as f: - f.write(json.dumps(lockfile, indent=4, separators=(',', ': '))) + json.dump(lockfile, f, indent=4, separators=(',', ': '), sort_keys=True) # Purge the virtualenv download dir, for next time. with spinner():