Use `with` in `macdeployqtplus` script.

This commit is contained in:
Chris Gavin 2017-04-25 09:14:57 +01:00
parent 4f3ac7ddd7
commit e8babc4330
1 changed files with 2 additions and 3 deletions

View File

@ -674,9 +674,8 @@ else:
if verbose >= 2:
print("+ Installing qt.conf +")
f = open(os.path.join(applicationBundle.resourcesPath, "qt.conf"), "wb")
f.write(qt_conf.encode())
f.close()
with open(os.path.join(applicationBundle.resourcesPath, "qt.conf"), "wb") as f:
f.write(qt_conf.encode())
# ------------------------------------------------