Skip to content

Commit

Permalink
fix: try fix CI
Browse files Browse the repository at this point in the history
  • Loading branch information
enfipy committed Feb 27, 2024
1 parent 55ce8b7 commit 4f4ba68
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ jobs:
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
toolchain: stable
components: rustfmt, clippy
override: true
- name: Check the format
Expand Down
6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ crossbow-android = { path = "platform/android", version = "0.2.3", optional = tr
[target.'cfg(target_os = "ios")'.dependencies]
crossbow-ios = { path = "platform/ios", version = "0.2.3", optional = true }

[patch.crates-io]
bevy = { git = "https://github.com/dodorare/bevy", rev = "732fc8c585ebd3a622153771a8c51ace93024a04" }
miniquad = { git = "https://github.com/not-fl3/miniquad", rev = "d67ffe6950cf73df307e2d23aaa4726f14399985" }
# [patch.crates-io]
# bevy = { git = "https://github.com/dodorare/bevy", rev = "732fc8c585ebd3a622153771a8c51ace93024a04" }
# miniquad = { git = "https://github.com/not-fl3/miniquad", rev = "d67ffe6950cf73df307e2d23aaa4726f14399985" }

[features]
default = ["android", "ios"]
Expand Down
2 changes: 1 addition & 1 deletion examples/crossbow-plugins/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ edition = "2021"
crossbow = { version = "0.2.3", path = "../../" }
log = "0.4"
anyhow = "1.0"
macroquad = "=0.3.7"
macroquad = "0.4.5"

[target.'cfg(target_os = "android")'.dependencies]
play-core = { version = "0.2.3", path = "../../plugins/play-core" }
Expand Down
2 changes: 1 addition & 1 deletion examples/macroquad-3d/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ edition = "2021"
crossbow = { version = "0.2.3", path = "../../" }
log = "0.4"
anyhow = "1.0"
macroquad = "=0.3.7"
macroquad = "0.4.5"

[package.metadata]
app_name = "Macroquad 3D"
Expand Down
14 changes: 10 additions & 4 deletions examples/macroquad-3d/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,15 @@ async fn main() -> anyhow::Result<()> {
draw_cube_wires(vec3(0., 1., 6.), vec3(2., 2., 2.), DARKBLUE);
draw_cube_wires(vec3(2., 1., 2.), vec3(2., 2., 2.), YELLOW);

draw_plane(vec3(-8., 0., -8.), vec2(5., 5.), rust_logo, WHITE);

draw_cube(vec3(-5., 1., -2.), vec3(2., 2., 2.), rust_logo, WHITE);
draw_cube(vec3(-5., 1., 2.), vec3(2., 2., 2.), rust_logo, WHITE);
draw_plane(vec3(-8., 0., -8.), vec2(5., 5.), Some(&rust_logo), WHITE);

draw_cube(
vec3(-5., 1., -2.),
vec3(2., 2., 2.),
Some(&rust_logo),
WHITE,
);
draw_cube(vec3(-5., 1., 2.), vec3(2., 2., 2.), Some(&rust_logo), WHITE);
draw_cube(vec3(2., 0., -2.), vec3(0.4, 0.4, 0.4), None, BLACK);

draw_sphere(vec3(-8., 0., 0.), 1., None, BLUE);
Expand All @@ -45,6 +50,7 @@ async fn main() -> anyhow::Result<()> {

// Workaround. Failed to get assets on windows from the macroquad .load_texture() method
// through the relative path to asset
#[cfg(not(target_os = "android"))]
fn get_assets_from_path() -> String {
let manifest_dir = std::path::PathBuf::from(env!("CARGO_MANIFEST_DIR"));
let assets_dir = manifest_dir.parent().unwrap().parent().unwrap();
Expand Down
2 changes: 1 addition & 1 deletion examples/macroquad-permissions/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ edition = "2021"
crossbow = { version = "0.2.3", path = "../../" }
log = "0.4"
anyhow = "1.0"
macroquad = "=0.3.7"
macroquad = "0.4.5"

[target.'cfg(target_os = "android")'.dependencies]
admob-android = { version = "0.2.3", path = "../../plugins/admob-android" }
Expand Down
12 changes: 10 additions & 2 deletions rustfmt.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,10 @@
comment_width = 90
wrap_comments = true
use_field_init_shorthand = true
newline_style = "Unix"

# The following lines may be uncommented on nightly Rust.
# Once these features have stabilized, they should be added to the always-enabled options above.
# unstable_features = true
# imports_granularity = "Crate"
# wrap_comments = true
# comment_width = 100
# normalize_comments = true

0 comments on commit 4f4ba68

Please sign in to comment.