reformat.
[bertos.git] / wizard / create_preset.py
index 88fe9c1048104cf7a7dbf78a7ac7ac556b24ae55..5f303ff5166ac51420767481e24163b668ea1501 100644 (file)
@@ -72,7 +72,6 @@ assert(os.path.exists(preset_dir + "/" + hw_path     + "/hw"))
 assert(os.path.exists(preset_dir + "/" + bertos_path + "/bertos"))
 
 s["BERTOS_PATH"] = bertos_path
-s["PRESET"] = True
 s["PROJECT_HW_PATH"] = hw_path
 s["PROJECT_SRC_PATH"] = "."
 s["PRESET"] = True
@@ -80,9 +79,7 @@ pprint.pprint(s)
 p = open(preset_dir + "/project.bertos", "w")
 pickle.dump(s, p)
 
-p = open(preset_dir + "/.spec", "w")
-p.write("name = '%s preset'" % pname)
-p.close()
+open(preset_dir + "/.spec", "w").write("name = '%s preset'" % pname)
 
 bertos_path = os.path.abspath(preset_dir + "/" + bertos_path)
 hw_path = os.path.abspath(preset_dir + "/" + hw_path)