Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
SkyEye-FAST committed Jun 5, 2024
1 parent 8a88922 commit 34b6779
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 128 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:

- name: Get Minecraft version
run: |
cat version.txt
cat mc_lang/version.txt
echo "ver=$(<version.txt)" >> "$GITHUB_ENV"
- name: Release
Expand Down
2 changes: 1 addition & 1 deletion mc_lang
Submodule mc_lang updated 17 files
+4 −2 full/ja_jp.json
+3 −1 full/ko_kr.json
+3 −1 full/lzh.json
+2 −0 full/vi_vn.json
+2 −0 full/zh_cn.json
+2 −0 full/zh_hk.json
+6 −4 full/zh_tw.json
+70 −51 update.py
+2,010 −2,010 valid/en_us.json
+2,010 −2,010 valid/ja_jp.json
+2,010 −2,010 valid/ko_kr.json
+2,010 −2,010 valid/lzh.json
+2,010 −2,010 valid/vi_vn.json
+2,010 −2,010 valid/zh_cn.json
+2,010 −2,010 valid/zh_hk.json
+2,010 −2,010 valid/zh_tw.json
+1 −0 version.txt
9 changes: 3 additions & 6 deletions pack.py
Original file line number Diff line number Diff line change
Expand Up @@ -369,8 +369,7 @@ def save_to_json(
file_path = P / "output" / full_file_name
with open(file_path, "w", encoding="utf-8") as j:
json.dump(output_dict, j, indent=2, ensure_ascii=False)
end_time = time.time()
elapsed_time = end_time - start_time
elapsed_time = time.time() - start_time
size = f"{round(file_path.stat().st_size / 1024, 2)} KB"
print(f"已生成语言文件“{full_file_name}”,大小{size},耗时{elapsed_time:.2f} s。")

Expand All @@ -391,8 +390,7 @@ def main() -> None:
save_to_json("zh_cn", "zh_gr", to_romatzyh, fixed_zh_gr)
save_to_json("zh_cn", "zh_cy", to_cyrillic, fixed_zh_cy)
save_to_json("zh_cn", "zh_xj", to_xiaojing, fixed_zh_xj)
main_end_time = time.time()
main_elapsed_time = main_end_time - main_start_time
main_elapsed_time = time.time() - main_start_time
print(f"\n语言文件生成完毕,共耗时{main_elapsed_time:.2f} s。")


Expand All @@ -403,8 +401,7 @@ def main() -> None:
z.write(P / "pack.mcmeta", arcname="pack.mcmeta")
for lang_file in P.glob("output/*.json"):
z.write(lang_file, arcname=f"assets/minecraft/lang/{lang_file.name}")
zip_end_time = time.time()
zip_elapsed_time = zip_end_time - zip_start_time
zip_elapsed_time = time.time() - zip_start_time
pack_size = f"{round(pack_path.stat().st_size / 1024, 2)} KB"
print(f"\n资源包“{pack_path.name}”打包完毕,大小{pack_size},打包耗时{zip_elapsed_time:.2f} s。")

Expand Down
119 changes: 0 additions & 119 deletions source.py

This file was deleted.

1 change: 0 additions & 1 deletion version.txt

This file was deleted.

0 comments on commit 34b6779

Please sign in to comment.