publish test

This commit is contained in:
xaoyo 2023-11-28 19:12:39 +08:00
parent 5297c0c015
commit 97eb65d13f
3 changed files with 26 additions and 26 deletions

View File

@ -45,28 +45,28 @@ jobs:
run: |
ls -l dist
ls -l "${{ github.workspace }}"
cd dist
./pywxdump.exe
# cd dist
# ./pywxdump.exe
# - name: Publish package with Twine # 使用 Twine 发布到 PyPI
# run: |
# twine upload dist/*.whl dist/*.tar.gz
# env:
# TWINE_USERNAME: __token__
# TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
#
# - name: Create Release
# id: create_release
# uses: softprops/action-gh-release@v1
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# with:
# tag_name: ${{ github.ref }}
# release_name: Release ${{ github.ref.tag }}
# body: |
# [Auto Release] Update PyWxDump to ${{ github.ref }}
# draft: false
# prerelease: false
# files: |
# dist/*.exe
# dist/*.whl
- name: Publish package with Twine # 使用 Twine 发布到 PyPI
run: |
twine upload dist/*.whl dist/*.tar.gz
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
- name: Create Release
id: create_release
uses: softprops/action-gh-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref.tag }}
body: |
[Auto Release] Update PyWxDump to ${{ github.ref }}
draft: false
prerelease: false
files: |
dist/*.exe
dist/*.whl

View File

@ -3,7 +3,7 @@ from setuptools import setup, find_packages
with open("README.md", "r", encoding="utf-8") as fh:
long_description = fh.read()
version = "2.2.13"
version = "2.2.14"
install_requires = [
"psutil",

View File

@ -68,7 +68,7 @@ coll = COLLECT(exe,
os.makedirs("dist", exist_ok=True)
# 将代码写入文件
with open("dist/tmp.py", "w", encoding="utf-8") as f:
f.write(code)
f.write(code.strip())
# 获取安装包的路径
package_path = site.getsitepackages()