-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
40b3b8b
commit 0a9d03f
Showing
6 changed files
with
66 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,24 @@ | ||
[package] | ||
name = "mtc-token-healing" | ||
[workspace] | ||
members = ["python"] | ||
|
||
[workspace.package] | ||
version = "0.1.1" | ||
edition = "2021" | ||
license = "MIT OR Apache-2.0" | ||
description = "Token healing implementation" | ||
repository = "https://github.com/ModelTC/mtc-token-healing" | ||
homepage = "https://github.com/ModelTC/mtc-token-healing" | ||
documentation = "https://docs.rs/mtc-token-healing" | ||
|
||
[package] | ||
name = "mtc-token-healing" | ||
version.workspace = true | ||
edition.workspace = true | ||
license.workspace = true | ||
description.workspace = true | ||
repository.workspace = true | ||
homepage.workspace = true | ||
documentation.workspace = true | ||
readme = "README.md" | ||
authors = ["Chielo Newctle <[email protected]>"] | ||
exclude = ["release-plz.toml", ".github"] | ||
|
@@ -32,3 +44,8 @@ tokio = { version = "1.37.0", features = ["rt-multi-thread"] } | |
|
||
[package.metadata.docs.rs] | ||
all-features = true | ||
|
||
[profile.release] | ||
lto = true | ||
strip = true | ||
opt-level = "z" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
[package] | ||
name = "mtc-token-healing-py" | ||
version.workspace = true | ||
edition.workspace = true | ||
license.workspace = true | ||
description.workspace = true | ||
repository.workspace = true | ||
homepage.workspace = true | ||
documentation.workspace = true | ||
|
||
[lib] | ||
name = "mtc_token_healing" | ||
crate-type = ["cdylib"] | ||
|
||
[dependencies] | ||
mtc-token-healing = { version = "0.1.0", path = "..", features = ["pyo3"] } | ||
pyo3 = { version = "0.21.2", features = ["extension-module", "generate-import-lib", "abi3-py38"] } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
from .mtc_token_healing import CountInfo | ||
|
||
__all__ = [ | ||
"CountInfo", | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
class CountInfo: ... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
[build-system] | ||
requires = ["maturin>=1.3,<2.0"] | ||
build-backend = "maturin" | ||
|
||
[project] | ||
name = "mtc_token_healing" | ||
requires-python = ">=3.8" | ||
classifiers = [ | ||
"Programming Language :: Rust", | ||
"Programming Language :: Python :: Implementation :: CPython", | ||
"Programming Language :: Python :: Implementation :: PyPy", | ||
] | ||
dynamic = ["version"] | ||
|
||
[project.optional-dependencies] | ||
test = ["pytest"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
use ::mtc_token_healing::CountInfo; | ||
use pyo3::prelude::*; | ||
|
||
#[pymodule] | ||
fn mtc_token_healing(_py: Python, m: &Bound<'_, PyModule>) -> PyResult<()> { | ||
m.add_class::<CountInfo>()?; | ||
Ok(()) | ||
} |