0.3.1 stable release

This commit is contained in:
ykcheungab
2026-04-17 09:58:30 +08:00
parent 7a49fd76e6
commit fdc4ffd25f
11 changed files with 208 additions and 211 deletions
+13 -2
View File
@@ -39,6 +39,16 @@ def find_compiled_extension(output_dir: Path) -> Path:
return sorted(candidates, key=lambda p: len(p.name))[0]
def move_wheel_to_sdk(wheel_path: Path, version: str) -> Path:
sdk_version_dir = Path("SDK") / version
sdk_version_dir.mkdir(parents=True, exist_ok=True)
dest_wheel = sdk_version_dir / wheel_path.name
if dest_wheel.exists():
dest_wheel.unlink()
shutil.move(str(wheel_path), str(dest_wheel))
return dest_wheel
def build():
install_nuitka()
@@ -143,9 +153,10 @@ setup(
print("\n=== Building Wheel ===")
subprocess.check_call([sys.executable, "setup.py", "bdist_wheel"], cwd=dist_dir)
wheels = list((dist_dir / "dist").glob("*.whl"))
wheels = sorted((dist_dir / "dist").glob("*.whl"))
if wheels:
print(f"\n[SUCCESS] Wheel created: {wheels[0]}")
final_wheel = move_wheel_to_sdk(wheels[0], version)
print(f"\n[SUCCESS] Wheel created and moved to: {final_wheel}")
else:
print("\n[ERROR] Wheel not found.")