bevy/crates/bevy_asset
François 49bc6cfd62
support file operations in single threaded context (#10312)
# Objective

- Fixes #10209 
- Assets should work in single threaded

## Solution

- In single threaded mode, don't use `async_fs` but fallback on
`std::fs` with a thin layer to mimic the async API
- file `file_asset.rs` is the async imps from `mod.rs`
- file `sync_file_asset.rs` is the same with `async_fs` APIs replaced by
`std::fs`
- which module is used depends on the `multi-threaded` feature

---------

Co-authored-by: Carter Anderson <mcanders1@gmail.com>
2023-11-03 23:00:34 +00:00
..
macros Fix unused variable warning for simple AssetV2 derives (#9961) 2023-09-29 08:08:13 +00:00
src support file operations in single threaded context (#10312) 2023-11-03 23:00:34 +00:00
Cargo.toml few fmt tweaks (#10264) 2023-10-25 19:20:17 +00:00