aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorHsiangNianian <i@jyunko.cn>2025-11-06 11:26:52 +0800
committerHsiangNianian <i@jyunko.cn>2025-11-06 11:26:52 +0800
commit4f7762c1bb7ce719c72c466cebdb00d5def8ea5e (patch)
tree38fb539574f0c55e19dc5111b8680048961b0b80
parent3d4081897e267c7fae5f11a7dd55826574e6941b (diff)
downloadmvp-4f7762c1bb7ce719c72c466cebdb00d5def8ea5e.tar.gz
mvp-4f7762c1bb7ce719c72c466cebdb00d5def8ea5e.zip
refactor: refactor project structure and update configurations for MVP implementation
-rw-r--r--.github/workflows/CI.yml4
-rw-r--r--Cargo.lock2
-rw-r--r--Cargo.toml6
-rw-r--r--README.md4
-rw-r--r--mvp/__init__.py (renamed from maturin_template/__init__.py)0
-rw-r--r--mvp/__main__.py (renamed from maturin_template/__main__.py)2
-rw-r--r--pyproject.toml13
-rw-r--r--src/main.rs2
8 files changed, 17 insertions, 16 deletions
diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml
index 34d6b29..f165f9d 100644
--- a/.github/workflows/CI.yml
+++ b/.github/workflows/CI.yml
@@ -1,4 +1,4 @@
-# This file is autogenerated by maturin v1.8.2
+# This file is autogenerated by maturin v1.9.6
# To update, run
#
# maturin generate-ci github
@@ -155,7 +155,7 @@ jobs:
steps:
- uses: actions/download-artifact@v4
- name: Generate artifact attestation
- uses: actions/attest-build-provenance@v1
+ uses: actions/attest-build-provenance@v2
with:
subject-path: 'wheels-*/*'
- name: Publish to PyPI
diff --git a/Cargo.lock b/Cargo.lock
index 07b9981..26fbfe6 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -111,7 +111,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf"
[[package]]
-name = "maturin_template"
+name = "mvp"
version = "0.1.0"
dependencies = [
"clap",
diff --git a/Cargo.toml b/Cargo.toml
index 45ed7d6..af366c2 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,13 +1,11 @@
[package]
-name = "maturin_template"
+name = "mvp"
version = "0.1.0"
edition = "2021"
-# 生成 CLI 可执行文件
[[bin]]
-name = "maturin_template" # CLI 名称与 Python 包名一致
+name = "mvp"
path = "src/main.rs"
[dependencies]
-# 例如添加 clap 处理 CLI 参数
clap = { version = "4.0", features = ["derive"] } \ No newline at end of file
diff --git a/README.md b/README.md
index e1f971e..1d71f9f 100644
--- a/README.md
+++ b/README.md
@@ -1,3 +1,3 @@
-# maturin-template
+# MVP
-> maturin template for bin(and cli program). \ No newline at end of file
+> MVP Implementation in Rust and Python by HydroRoll-Team \ No newline at end of file
diff --git a/maturin_template/__init__.py b/mvp/__init__.py
index e69de29..e69de29 100644
--- a/maturin_template/__init__.py
+++ b/mvp/__init__.py
diff --git a/maturin_template/__main__.py b/mvp/__main__.py
index 02df57d..2402016 100644
--- a/maturin_template/__main__.py
+++ b/mvp/__main__.py
@@ -3,7 +3,7 @@ import sys
def run_cli(*args):
result = subprocess.run(
- ["maturin_template", *args],
+ ["mvp", *args],
capture_output=True,
text=True
)
diff --git a/pyproject.toml b/pyproject.toml
index 7297f99..73ec6d0 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -3,13 +3,13 @@ requires = ["maturin>=1.0,<2.0"]
build-backend = "maturin"
[project]
-name = "maturin_template"
+name = "mvp"
dynamic = ["version"]
-description = "A Rust CLI bundled as a Python package"
+description = "MVP Implementation in Rust and Python by HydroRoll-Team"
authors = [
- { name = "Your Name", email = "your.email@example.com" }
+ { name = "HsiangNianian", email = "leader@hydroroll.team" }
]
-requires-python = ">=3.8"
+requires-python = ">=3.11"
readme = "README.md"
license = { text = "MIT" }
classifiers = [
@@ -18,7 +18,10 @@ classifiers = [
"Programming Language :: Python :: 3",
]
+[project.scripts]
+mvp = "mvp.__main__:main"
+
[tool.maturin]
bindings = "bin"
# manifest-path = "Cargo.toml"
-module-name = "maturin_template" \ No newline at end of file
+module-name = "mvp" \ No newline at end of file
diff --git a/src/main.rs b/src/main.rs
index c3c3fd4..c3fd598 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -10,4 +10,4 @@ struct Args {
fn main() {
let args = Args::parse();
println!("Hello from CLI, {}!", args.name);
-} \ No newline at end of file
+}