Skip to content

Commit df7e4a4

Browse files
authored
Hotfix SI: PyWordSegment | added support for arm64 m1 build (#5)
1 parent 9b4e7b4 commit df7e4a4

File tree

4 files changed

+185
-16
lines changed

4 files changed

+185
-16
lines changed

.github/workflows/deploy.yml

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,32 @@ jobs:
3232
profile: minimal
3333
toolchain: stable
3434
override: true
35+
- name: Install Cross-compilers (macOS)
36+
if: matrix.os == 'macos-latest'
37+
run: |
38+
brew install FiloSottile/musl-cross/musl-cross
39+
brew install mingw-w64
3540
- name: Publish Package
36-
uses: messense/maturin-action@v1
41+
uses: PyO3/maturin-action@v1
3742
with:
3843
command: publish
3944
args: --username=__token__ ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == '3.7' && '' || '--no-sdist' }} --interpreter=python${{ !startsWith(matrix.os, 'windows') && matrix.python-version || '' }}
4045
env:
4146
MATURIN_PASSWORD: ${{ secrets.pypi_password }}
47+
if: matrix.os != 'macos-latest'
48+
- name: Publish macOS (x86_64) Package
49+
if: matrix.os == 'macos-latest'
50+
uses: PyO3/maturin-action@v1
51+
with:
52+
command: publish
53+
args: --username=__token__ --interpreter=python${{ matrix.python-version }} --target=x86_64-apple-darwin --no-sdist
54+
env:
55+
MATURIN_PASSWORD: ${{ secrets.pypi_password }}
56+
- name: Publish macOS (arm64) Package
57+
if: matrix.os == 'macos-latest'
58+
uses: PyO3/maturin-action@v1
59+
with:
60+
command: publish
61+
args: --username=__token__ --interpreter=python${{ matrix.python-version }} --target=aarch64-apple-darwin --no-sdist
62+
env:
63+
MATURIN_PASSWORD: ${{ secrets.pypi_password }}

Cargo.toml

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "pywordsegment"
3-
version = "0.4.1"
3+
version = "0.4.2"
44
authors = ["Gal Ben David <[email protected]>"]
55
edition = "2021"
66
description = "Concatenated-word segmentation Python library written in Rust"
@@ -16,19 +16,6 @@ keywords = [
1616
]
1717

1818
[package.metadata.maturin]
19-
requires-python = ">=3.7"
20-
classifier = [
21-
"License :: OSI Approved :: MIT License",
22-
"Operating System :: MacOS",
23-
"Operating System :: Microsoft",
24-
"Operating System :: POSIX :: Linux",
25-
"Programming Language :: Python :: 3.7",
26-
"Programming Language :: Python :: 3.8",
27-
"Programming Language :: Python :: 3.9",
28-
"Programming Language :: Python :: 3.10",
29-
"Programming Language :: Python :: 3.11",
30-
"Programming Language :: Rust",
31-
]
3219

3320
[lib]
3421
name = "pywordsegment"

poetry.lock

Lines changed: 160 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ sdist-include = [
1414

1515
[tool.poetry]
1616
name = "pywordsegment"
17-
version = "0.4.1"
17+
version = "0.4.2"
1818
authors = ["Gal Ben David <[email protected]>"]
1919
description = "Concatenated-word segmentation Python library written in Rust"
2020
readme = "README.md"

0 commit comments

Comments
 (0)