mirror of
https://github.com/italicsjenga/agb.git
synced 2024-12-23 16:21:33 +11:00
Allow warnings when developing, but still fail CI
This commit is contained in:
parent
d51f61a6fb
commit
61ed2b905d
|
@ -6,5 +6,5 @@ build-std-features = ["compiler-builtins-mem"]
|
||||||
target = "thumbv4t-none-eabi"
|
target = "thumbv4t-none-eabi"
|
||||||
|
|
||||||
[target.thumbv4t-none-eabi]
|
[target.thumbv4t-none-eabi]
|
||||||
rustflags = ["-Clink-arg=-Tgba.ld", "-Ctarget-cpu=arm7tdmi", "-Dwarnings", "-Dclippy::all", "-Aclippy::empty-loop"]
|
rustflags = ["-Clink-arg=-Tgba.ld", "-Ctarget-cpu=arm7tdmi"]
|
||||||
runner = "mgba-test-runner"
|
runner = "mgba-test-runner"
|
||||||
|
|
|
@ -30,16 +30,10 @@ pub fn write_level(
|
||||||
map.set_tile(
|
map.set_tile(
|
||||||
vram,
|
vram,
|
||||||
(i as u16, 0).into(),
|
(i as u16, 0).into(),
|
||||||
&tileset,
|
tileset,
|
||||||
TileSetting::from_raw(tile),
|
TileSetting::from_raw(tile),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
map.set_scroll_pos(
|
map.set_scroll_pos((-(WIDTH / 2 - 7 * 8 / 2) as u16, -(HEIGHT / 2 - 4) as u16).into());
|
||||||
(
|
|
||||||
-(WIDTH / 2 - 7 as i32 * 8 / 2) as u16,
|
|
||||||
-(HEIGHT / 2 - 4) as u16,
|
|
||||||
)
|
|
||||||
.into(),
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
5
justfile
5
justfile
|
@ -1,4 +1,5 @@
|
||||||
export CARGO_TARGET_DIR := env_var_or_default('CARGO_TARGET_DIR', justfile_directory() + "/target")
|
export CARGO_TARGET_DIR := env_var_or_default('CARGO_TARGET_DIR', justfile_directory() + "/target")
|
||||||
|
CLIPPY_ARGUMENTS := "-Dwarnings -Dclippy::all -Aclippy::empty-loop"
|
||||||
|
|
||||||
build: build-roms
|
build: build-roms
|
||||||
|
|
||||||
|
@ -61,7 +62,7 @@ _build-rom folder name:
|
||||||
TARGET_FOLDER="${CARGO_TARGET_DIR:-$GAME_FOLDER/target}"
|
TARGET_FOLDER="${CARGO_TARGET_DIR:-$GAME_FOLDER/target}"
|
||||||
GBA_FILE="$TARGET_FOLDER/$GAME_NAME.gba"
|
GBA_FILE="$TARGET_FOLDER/$GAME_NAME.gba"
|
||||||
|
|
||||||
(cd "$GAME_FOLDER" && cargo build --release --target thumbv4t-none-eabi && cargo clippy --release --target thumbv4t-none-eabi)
|
(cd "$GAME_FOLDER" && cargo build --release --target thumbv4t-none-eabi && cargo clippy --release --target thumbv4t-none-eabi -- {{CLIPPY_ARGUMENTS}})
|
||||||
|
|
||||||
mkdir -p examples/target/examples
|
mkdir -p examples/target/examples
|
||||||
|
|
||||||
|
@ -87,7 +88,7 @@ _test-debug crate:
|
||||||
just _build-debug {{crate}}
|
just _build-debug {{crate}}
|
||||||
(cd "{{crate}}" && cargo test)
|
(cd "{{crate}}" && cargo test)
|
||||||
_clippy crate:
|
_clippy crate:
|
||||||
(cd "{{crate}}" && cargo clippy --examples --tests)
|
(cd "{{crate}}" && cargo clippy --examples --tests -- {{CLIPPY_ARGUMENTS}})
|
||||||
_clean crate:
|
_clean crate:
|
||||||
(cd "{{crate}}" && cargo clean)
|
(cd "{{crate}}" && cargo clean)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue