From d62dcc2d3c17fd0df3dcfa8c6b0521eefd3589bb Mon Sep 17 00:00:00 2001 From: shenjack <3695888@qq.com> Date: Sat, 10 Jun 2023 17:09:57 +0800 Subject: [PATCH] look like useless? --- .github/workflows/nuitka.yml | 27 +-------------------------- nuitka_build.py | 14 +++++++------- 2 files changed, 8 insertions(+), 33 deletions(-) diff --git a/.github/workflows/nuitka.yml b/.github/workflows/nuitka.yml index 1fa35ac..b4e3e6f 100644 --- a/.github/workflows/nuitka.yml +++ b/.github/workflows/nuitka.yml @@ -88,31 +88,6 @@ jobs: python nuitka_build.py --github # 集成的构建脚本 好耶! - # - name: after build - # shell: pwsh - # run: | - # Get-ChildItem libs/fonts/Fira_Code -Recurse | Remove-Item -Force - # Get-ChildItem libs/fonts/scientifica -Recurse | Remove-Item -Force - # Remove-Item libs/fonts/Monocraft.otf -Force - # Remove-Item libs/fonts/SmileySans-Oblique.ttf -Force - # Get-ChildItem libs/fonts/HarmonyOS_Sans/HarmonyOS_Sans_Condensed/* -Recurse | Remove-Item -Force - # Get-ChildItem libs/fonts/HarmonyOS_Sans/HarmonyOS_Sans/* -Recurse | Remove-Item -Force - # - # Copy-Item libs/fonts build\DR.dist\libs\fonts -Recurse - # # Copy-Item libs\pyglet\ build\DR.dist -Recurse - # - # Rename-Item build/DR.dist Difficult-Rocket - # python ./.github/workflows/post_compile.py - - - upload-artifact: - runs-on: ubuntu-latest - - needs: - - build-nuitka - - steps: - # 获取短 sha - name: Get short commit sha id: get_short_sha @@ -129,4 +104,4 @@ jobs: with: name: Difficult-Rocket_v${{env.DR_version}}-${{runner.os}}${{matrix.python-version}}-Build.${{github.run_number}}+${{env.short_sha}} path: | - build/main.zip + build/github/DR.dist diff --git a/nuitka_build.py b/nuitka_build.py index 0be5ab0..d1559f2 100644 --- a/nuitka_build.py +++ b/nuitka_build.py @@ -76,11 +76,11 @@ if __name__ == '__main__': traceback.print_exc() print('Remove Useless Files Done!') # 压缩 - with zipfile.ZipFile(Path('./build/Difficult_Rocket.zip'), 'w', zipfile.ZIP_DEFLATED, compresslevel=9) as dist_zip: - for path, sub_paths, sub_files in os.walk(compiler.output_path / 'DR.dist'): - print(f'writing {path}') - for file in sub_files: - file_path = os.path.join(path, file) - dist_zip.write(file_path) - print('Zip Done!') + # with zipfile.ZipFile(Path('./build/Difficult_Rocket.zip'), 'w', zipfile.ZIP_DEFLATED, compresslevel=9) as dist_zip: + # for path, sub_paths, sub_files in os.walk(compiler.output_path / 'DR.dist'): + # print(f'writing {path}') + # for file in sub_files: + # file_path = os.path.join(path, file) + # dist_zip.write(file_path) + # print('Zip Done!') sys.exit(0)