From 9a8124392e137652a27a6f8433f22717bba815fc Mon Sep 17 00:00:00 2001 From: xaoyo Date: Mon, 27 Nov 2023 11:17:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0workflows?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/publish.yml | 18 ++++++++++++++---- README.md | 1 + tests/build_exe.py | 4 ++-- 3 files changed, 17 insertions(+), 6 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 469bab0e..a2c3640f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -24,16 +24,23 @@ jobs: with: python-version: 3.8 # 指定 Python 版本 (3.8) - - name: Install dependencies + - name: Install dependencies # 安装依赖 run: | python -m pip install --upgrade pip pip install build python -m pip install --upgrade twine + pip install pyinstaller - name: Build package - run: python -m build + run: | + python -m build + python tests/build_exe.py + + - name: test + run: | + ls -l dist - - name: Publish package with Twine + - name: Publish package with Twine # 使用 Twine 发布到 PyPI run: | twine upload dist/* env: @@ -42,7 +49,7 @@ jobs: - name: Create Release id: create_release - uses: actions/create-release@v1 + uses: softprops/action-gh-release@v1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: @@ -52,6 +59,9 @@ jobs: [Auto Release] Update PyWxDump draft: false prerelease: false + files: | + dist/*.exe + dist/*.whl - name: Upload .whl file uses: actions/upload-artifact@v2 diff --git a/README.md b/README.md index 10df6ce0..f15c56c9 100644 --- a/README.md +++ b/README.md @@ -57,6 +57,7 @@ * 4.生成年度可视化报告 * 5.创建GUI图形界面,方便使用 * 6.查看群聊中具体发言成员的ID [#31](https://github.com/xaoyaoo/PyWxDump/issues/31) +* 7.完善操作文档,增加更多的使用方法 注: 欢迎大家提供更多的想法,或者提供代码,一起完善这个项目,欢迎加入交流qq群:577704006。 ![img.png](./doc/img.png) diff --git a/tests/build_exe.py b/tests/build_exe.py index 8376c995..da44a7be 100644 --- a/tests/build_exe.py +++ b/tests/build_exe.py @@ -23,9 +23,9 @@ version_list_path = os.path.join(package_path,'pywxdump', 'version_list.json') # 执行打包命令 - cmd = f'pyinstaller --onefile --clean --add-data "{version_list_path};pywxdump" dist/tmp.py' + cmd = f'pyinstaller --onefile --clean --add-data "{version_list_path};pywxdump" --distpath=dist --workpath=build --specpath=build --name=pywxdump dist/tmp.py' print(cmd) - os.system(cmd) + # os.system(cmd) else: print("未找到安装包路径")