Skip to content

Latest commit

 

History

History
27 lines (19 loc) · 685 Bytes

README.md

File metadata and controls

27 lines (19 loc) · 685 Bytes

flake-outputs

Get buildable outputs of a flake, for projects that use nix-systems.

Usage

# Get all buildable flake outputs
OUTS=$(nix run github:nix-systems/flake-outputs github:srid/haskell-template)

for OUT in $OUTS
do
  # Build them
  nix build --no-link .#"$OUT"
  # Push to cachix
  nix build --no-link --print-out-paths .#"$OUT" | cachix push mycache
done

Rationale

This is useful in CI1 to automate building of all outputs, regardless of IFD or use of multi-systems.

Alternatives

Footnotes

  1. Jenkins, for example: https://github.com/juspay/jenkins-nix-ci/issues/12