@@ -95,7 +95,7 @@ def format_python(session: Session) -> None:
9595 session .run ("uvx" , "ruff" , "format" , * session .posargs )
9696
9797
98- {% if cookiecutter .add_rust_extension == "y" - % }
98+ {% if cookiecutter .add_rust_extension - % }
9999@nox .session (python = False , name = "format-rust" , tags = [FORMAT , RUST ])
100100def format_rust (session : Session ) -> None :
101101 """Run Rust code formatter (cargo fmt)."""
@@ -113,7 +113,7 @@ def lint_python(session: Session) -> None:
113113 session .run ("uvx" , "ruff" , "check" , "--fix" , "--verbose" )
114114
115115
116- {% if cookiecutter .add_rust_extension == "y" - % }
116+ {% if cookiecutter .add_rust_extension - % }
117117@nox .session (python = False , name = "lint-rust" , tags = [LINT , RUST ])
118118def lint_rust (session : Session ) -> None :
119119 """Run Rust code linters (cargo clippy)."""
@@ -144,7 +144,7 @@ def security_python(session: Session) -> None:
144144 session .run ("uvx" , "pip-audit" )
145145
146146
147- {% if cookiecutter .add_rust_extension == 'y' - % }
147+ {% if cookiecutter .add_rust_extension - % }
148148@nox .session (python = False , name = "security-rust" , tags = [SECURITY , RUST ])
149149def security_rust (session : Session ) -> None :
150150 """Run code security checks (cargo audit)."""
@@ -176,7 +176,7 @@ def tests_python(session: Session) -> None:
176176 )
177177
178178
179- {% if cookiecutter .add_rust_extension == 'y' - % }
179+ {% if cookiecutter .add_rust_extension - % }
180180@nox .session (python = False , name = "tests-rust" , tags = [TEST , RUST , CI ])
181181def tests_rust (session : Session ) -> None :
182182 """Test the project's rust crates."""
@@ -207,7 +207,7 @@ def docs_build(session: Session) -> None:
207207def build_python (session : Session ) -> None :
208208 """Build sdist and wheel packages (uv build)."""
209209 session .log (f"Building sdist and wheel packages with py{ session .python } ." )
210- {% if cookiecutter .add_rust_extension == "y" - % }
210+ {% if cookiecutter .add_rust_extension - % }
211211 session .run ("maturin" , "develop" , "--uv" )
212212 {% else - % }
213213 session .run ("uv" , "build" , "--sdist" , "--wheel" , "--out-dir" , "dist/" , external = True )
@@ -289,7 +289,7 @@ def publish_python(session: Session) -> None:
289289 session .run ("uv" , "publish" , "dist/*" , * session .posargs , external = True )
290290
291291
292- {% if cookiecutter .add_rust_extension == "y" - % }
292+ {% if cookiecutter .add_rust_extension - % }
293293@nox .session (python = False , name = "publish-rust" , tags = [RELEASE ])
294294def publish_rust (session : Session ) -> None :
295295 """Publish built crates to crates.io."""
0 commit comments