Merge pull request #1658 from matmair/fix-whitespace-paths

fix whitespaces in paths
This commit is contained in:
Oliver 2021-06-14 21:39:51 +10:00 committed by GitHub
commit 8e6691ce36
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -282,7 +282,7 @@ def export_records(c, filename='data.json'):
tmpfile = f"{filename}.tmp"
cmd = f"dumpdata --indent 2 --output {tmpfile} {content_excludes()}"
cmd = f"dumpdata --indent 2 --output '{tmpfile}' {content_excludes()}"
# Dump data to temporary file
manage(c, cmd, pty=True)
@ -348,7 +348,7 @@ def import_records(c, filename='data.json'):
with open(tmpfile, "w") as f_out:
f_out.write(json.dumps(data, indent=2))
cmd = f"loaddata {tmpfile} -i {content_excludes()}"
cmd = f"loaddata '{tmpfile}' -i {content_excludes()}"
manage(c, cmd, pty=True)