Move the Rust crate to edition 2024 (#605)
Some checks are pending
CI / build-desktop (push) Waiting to run
CI / build-android (push) Waiting to run
CI / build-ios (push) Waiting to run

## Summary

Moves the `aventura` crate from Rust edition 2021 to 2024, which is the
Rust floor `CLAUDE.md` names for new code.

## Changes

- `src-tauri/Cargo.toml`: `edition = "2024"`.
- `src-tauri/src/main.rs`: edition 2024 makes `std::env::set_var`
unsafe, so the NVIDIA/Wayland `WEBKIT_DISABLE_DMABUF_RENDERER` call
(Linux only) is wrapped in an `unsafe` block. It runs first in `main`,
before `aventura_lib::run()` starts any thread.

No other source changes were needed.

## Verification

[CI
run](https://github.com/AventurasTeam/Aventuras/actions/runs/38110082406)
on this branch passed for all six build jobs: Windows, Linux, macOS
(Intel and ARM), Android and iOS. The Linux job compiles the
`cfg(target_os = "linux")` block that changed.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

https://claude.ai/code/session_01Mp6GGHh2aY397TuZXyUXKX


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Chores**
* Updated the app’s underlying build configuration. This does not change
how the app works for users.
* **Compatibility**
* The existing Linux NVIDIA/Wayland workaround continues to behave as
before; its detection and settings are unchanged.
* **User-visible changes**
* No new features or changes to the app’s interface or behavior are
included in this update.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
Tony Frazier 2026-10-11 00:33:22 -04:00 • committed by GitHub
parent ec8f40d253
commit 1195d048f9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 2 deletions

View file

@ -3,7 +3,7 @@ name = "aventura"
version = "0.7.12"
description = "AI-powered adventure and creative writing frontend"
authors = ["Contributors"]
edition = "2021"
edition = "2024"
[lib]
name = "aventura_lib"

View file

@ -6,7 +6,8 @@ fn main() {
// Only applied when an NVIDIA GPU is detected, so AMD/Intel users get full GPU acceleration.
#[cfg(target_os = "linux")]
if is_nvidia_wayland() {
std::env::set_var("WEBKIT_DISABLE_DMABUF_RENDERER", "1");
// SAFETY: nothing else has started a thread yet.
unsafe { std::env::set_var("WEBKIT_DISABLE_DMABUF_RENDERER", "1") };
}
aventura_lib::run()