Skip to content

Commit

Permalink
build(setup.py, pyproject.toml): 🛠️ 升级打包程序
Browse files Browse the repository at this point in the history
1. 更新为新的打包系统
  • Loading branch information
CangSpirit committed Jul 28, 2024
1 parent b8bb524 commit bb8b484
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 104 deletions.
17 changes: 7 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
export MAYA_BIN = C:\Program Files\Autodesk\Maya2022\bin
export MAYA_PY = ${MAYA_BIN}/mayapy.exe

.PHONY: clean make_rst_from_markdown dist publish test_publish
.IGNORE: clean

Expand All @@ -12,14 +9,14 @@ make_rst_from_markdown:
pandoc -f markdown -t rst README.md -o README.rst

dist: clean make_rst_from_markdown
"${MAYA_PY}" -m pip install 'twine>=1.5.0'
"${MAYA_PY}" setup.py bdist_wheel
py -3.10 -m pip install 'twine>=1.5.0'
py -3.10 -m build

check_dist: dist
"${MAYA_PY}" -m twine check dist/*
py -3.10 -m twine check dist/*

publish: dist
"${MAYA_PY}" -m twine upload --repository pypi dist/*
publish: dist check_dist
py -3.10 -m twine upload --repository pypi dist/*

test_publish: dist
"${MAYA_PY}" -m twine upload --repository testpypi dist/*
test_publish: dist check_dist
py -3.10 -m twine upload --repository testpypi dist/*
47 changes: 40 additions & 7 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,42 @@
[build-system]
requires = [
"setuptools>=24",
"wheel"
requires = ["setuptools>=42", "wheel"]
build-backend = "setuptools.build_meta"

[project]
name = "pyeal"
version = "1.0.5"
description = "Python 打包编译工具"
readme = "README.md"
authors = [
{ name = "cpcgskill", email = "[email protected]" }
]
#requires = [
# "setuptools>=24",
#]
build-backend = "setuptools.build_meta"
license = { text = "Apache Software License (Apache 2.0)" }
requires-python = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*"
classifiers = [
"License :: OSI Approved :: Apache Software License",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: Implementation :: CPython",
]

dependencies = [
"astunparse==1.6.3",
"argparse==1.4.0"
]

[project.urls]
Homepage = "https://github.com/cpcgskill/pyeal"
"Bug Tracker" = "https://github.com/cpcgskill/pyeal/issues"

[project.scripts]
pyeal = "pyeal.cli:main"

[tool.setuptools.packages.find]
where = ["src"]
87 changes: 0 additions & 87 deletions setup.py

This file was deleted.

0 comments on commit bb8b484

Please sign in to comment.