From ea1a247bc09eaf80ae4ebc02e536938d2a75da30 Mon Sep 17 00:00:00 2001 From: NateScarlet Date: Sat, 9 Mar 2019 19:40:34 +0800 Subject: [PATCH] Fix update.py --- update.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/update.py b/update.py index b805281..f915ab4 100755 --- a/update.py +++ b/update.py @@ -90,7 +90,8 @@ def main(): with open(temp_note_fd, 'w', encoding='utf-8') as f: f.write(now.strftime('%Y.%m.%d') + '\n\n```diff' + diff + '\n```') temp_zip_fd, temp_zip_name = mkstemp() - pack_data(temp_zip_fd) + with open(temp_zip_fd, 'w', encoding='utf-8') as f: + pack_data(f) subprocess.run(['hub', 'release', 'create', '-F', temp_note_name, '-a', temp_zip_name + '#JSON数据打包',