conduwuit/engage.toml

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

219 lines
4.1 KiB
TOML
Raw Normal View History

2023-12-21 00:33:31 +00:00
interpreter = ["bash", "-euo", "pipefail", "-c"]
[[task]]
name = "engage"
group = "versions"
script = "engage --version"
[[task]]
name = "nix"
group = "versions"
script = "nix --version"
[[task]]
name = "direnv"
group = "versions"
script = "direnv --version"
[[task]]
name = "rustc"
group = "versions"
script = "rustc --version"
[[task]]
name = "cargo"
group = "versions"
script = "cargo --version"
[[task]]
name = "cargo-fmt"
group = "versions"
script = "cargo fmt --version"
[[task]]
name = "rustdoc"
group = "versions"
script = "rustdoc --version"
[[task]]
name = "cargo-clippy"
group = "versions"
script = "cargo clippy -- --version"
[[task]]
name = "cargo-audit"
group = "versions"
script = "cargo audit --version"
[[task]]
name = "cargo-deb"
group = "versions"
script = "cargo deb --version"
[[task]]
name = "lychee"
group = "versions"
script = "lychee --version"
[[task]]
name = "markdownlint"
group = "versions"
script = "markdownlint --version"
[[task]]
name = "dpkg"
group = "versions"
script = "dpkg --version"
[[task]]
name = "cargo-audit"
group = "security"
script = "cargo audit -D warnings -D unmaintained -D unsound -D yanked"
2023-12-21 00:33:31 +00:00
[[task]]
name = "cargo-fmt"
group = "lints"
script = """
cargo fmt --check -- --color=always
"""
2023-12-21 00:33:31 +00:00
[[task]]
name = "cargo-doc"
group = "lints"
script = """
env DIRENV_DEVSHELL=all-features \
RUSTDOCFLAGS="-D warnings" \
direnv exec . \
cargo doc \
--workspace \
--profile test \
--all-features \
--no-deps \
--document-private-items \
--color always
2023-12-21 00:33:31 +00:00
"""
[[task]]
name = "clippy/default"
group = "lints"
script = """
cargo clippy \
--workspace \
--profile test \
--all-targets \
--color=always \
-- \
-D warnings
"""
[[task]]
name = "clippy/all"
2023-12-21 00:33:31 +00:00
group = "lints"
2024-04-27 23:10:31 +00:00
script = """
env DIRENV_DEVSHELL=all-features \
direnv exec . \
cargo clippy \
--workspace \
--profile test \
--all-targets \
--all-features \
--color=always \
-- \
-D warnings
2024-04-27 23:10:31 +00:00
"""
2023-12-21 00:33:31 +00:00
[[task]]
name = "clippy/jemalloc"
group = "lints"
script = """
cargo clippy \
--workspace \
--profile test \
--features jemalloc \
--all-targets \
--color=always \
-- \
-D warnings
"""
#[[task]]
#name = "clippy/hardened_malloc"
#group = "lints"
#script = """
#cargo clippy \
# --workspace \
# --features hardened_malloc \
# --all-targets \
# --color=always \
# -- \
# -D warnings
#"""
[[task]]
name = "lychee"
group = "lints"
script = "lychee --verbose --offline docs *.md --exclude development.md --exclude contributing.md --exclude testing.md"
[[task]]
name = "markdownlint"
group = "lints"
script = "markdownlint docs *.md || true" # TODO: fix the ton of markdown lints so we can drop `|| true`
2023-12-21 00:33:31 +00:00
[[task]]
name = "cargo/all"
group = "tests"
script = """
env DIRENV_DEVSHELL=all-features \
direnv exec . \
cargo test \
--workspace \
--profile test \
--all-targets \
--all-features \
--color=always \
-- \
--color=always
"""
[[task]]
name = "cargo/default"
2023-12-21 00:33:31 +00:00
group = "tests"
script = """
cargo test \
--workspace \
--profile test \
2023-12-21 00:33:31 +00:00
--all-targets \
--color=always \
-- \
--color=always
"""
# Checks if the generated example config differs from the checked in repo's
# example config.
[[task]]
name = "example-config"
group = "tests"
depends = ["cargo/default"]
script = """
git diff --exit-code conduwuit-example.toml
"""
# Ensure that the flake's default output can build and run without crashing
#
# This is a dynamically-linked jemalloc build, which is a case not covered by
# our other tests. We've had linking problems in the past with dynamic
# jemalloc builds that usually show up as an immediate segfault or "invalid free"
[[task]]
name = "nix-default"
group = "tests"
script = """
env DIRENV_DEVSHELL=dynamic \
CARGO_PROFILE="test" \
direnv exec . \
bin/nix-build-and-cache just .#default-test
env DIRENV_DEVSHELL=dynamic \
CARGO_PROFILE="test" \
direnv exec . \
nix run -L .#default-test -- --help && nix run -L .#default-test -- --version
"""