chore(nix): migrate flake to red-tape and bump nixpkgs#164
Merged
Conversation
- Replace the flake-utils boilerplate with red-tape's mkFlake, moving the devShell definition into a dedicated devshell.nix that red-tape picks up automatically. - Bump nixpkgs to nixos-25.11 and refresh the fenix / rust-analyzer lock entries that come with it. - Drop the stale shellHook comment now that the surrounding code has been tidied up.
The devshell only listed libb2/lz4/zstd, so `cargo check --all-features` (which turns on `static`) failed probing lzma/bzip2/z/xml2 — and then libarchive's own static link needed libcrypto. Add xz, bzip2, zlib, libxml2, and openssl so the full feature set builds out of the box.
`[package.metadata.docs.rs] all-features = true` turned on the `static` feature, which made build.rs pkg-config-probe libb2 — and that library is not present in the docs.rs crates-build-env, so docs for 0.16.0 fail to render (`doc_status: false`). The static_* features are compile-only (no public API surface), so documenting without them loses nothing. Explicitly list the feature sets users care about instead: futures_support and tokio_support (both transitively enable async_support).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
flake-utilstophaer/red-tape(a filesystem-convention flake builder). The devShell now lives indevshell.nixand is auto-wired by red-tape;flake.nixis down to a one-liner that delegates tored-tape.mkFlake.nixpkgsfromnixos-24.05tonixos-25.11and refreshfenix/rust-analyzerlock entries. Pinred-tape.inputs.nixpkgsto follow root so only one nixpkgs tree is evaluated.Cargo.tomlvialib.importTOMLso the fenix toolchain stays in sync withpackage.rust-version.xz,bzip2,zlib,libxml2, andopensslto the devShell socargo check --all-features(which turns on thestaticmeta-feature) builds out of the box in the shell.doc_status: false):[package.metadata.docs.rs] all-features = truewas activatingstatic, which madebuild.rsprobelibb2— not present in the docs.rscrates-build-env. Narrow tofeatures = ["futures_support", "tokio_support"]; thestatic_*features have no public API surface so docs lose nothing.Test plan
nix flake showlistsdevShells.${system}.defaultnix developenters the shell; reportsrustc 1.82.0,cargo 1.82.0,libarchive 3.8.6cargo check(default features) passes inside the devshellcargo check --all-featurespasses inside the devshellcargo test --libpassescargo doc --no-deps --features futures_support,tokio_supportrenders cleanly (mirrors the new docs.rs invocation)