mirror of
https://codeberg.org/JasterV/teatui.git
synced 2026-04-26 18:10:03 +00:00
chore: Add Makefile
This commit is contained in:
parent
52f6f0f36f
commit
5b82c75480
2 changed files with 48 additions and 1 deletions
47
Makefile.toml
Normal file
47
Makefile.toml
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
[config]
|
||||
default_to_workspace = false
|
||||
|
||||
[tasks.build]
|
||||
description = "Build binaries"
|
||||
command = "cargo"
|
||||
args = ["build", "--workspace", "--all-features"]
|
||||
|
||||
[tasks.clippy]
|
||||
description = "Runs clippy."
|
||||
clear = true
|
||||
command = "cargo"
|
||||
args = [
|
||||
"clippy",
|
||||
"--all-targets",
|
||||
"--workspace",
|
||||
"--",
|
||||
"-D",
|
||||
"warnings",
|
||||
"-W",
|
||||
"clippy::dbg_macro",
|
||||
]
|
||||
|
||||
[tasks.fmt-check]
|
||||
description = "Runs the cargo rustfmt plugin during CI."
|
||||
command = "cargo"
|
||||
args = ["fmt", "--all", "--", "--check"]
|
||||
|
||||
[tasks.deny-check]
|
||||
description = "Runs the cargo deny plugin during CI."
|
||||
command = "cargo"
|
||||
args = ["deny", "check"]
|
||||
|
||||
[tasks.test]
|
||||
description = "Runs tests."
|
||||
clear = true
|
||||
run_task = { name = ["doc-tests", "nextest"], fork = true }
|
||||
|
||||
[tasks.nextest]
|
||||
description = "Runs tests without dependencies."
|
||||
command = "cargo"
|
||||
args = ["nextest", "run", "--no-fail-fast", "${@}"]
|
||||
|
||||
[tasks.doc-tests]
|
||||
description = "Run doc tests"
|
||||
command = "cargo"
|
||||
args = ["test", "--doc"]
|
||||
|
|
@ -120,7 +120,7 @@ impl AppWidget {
|
|||
}
|
||||
|
||||
const fn alternate_colors(i: usize) -> Color {
|
||||
if i % 2 == 0 {
|
||||
if i.is_multiple_of(2) {
|
||||
NORMAL_ROW_BG
|
||||
} else {
|
||||
ALT_ROW_BG_COLOR
|
||||
|
|
|
|||
Loading…
Reference in a new issue