nixcfg/lib/default.nix

26 lines
405 B
Nix
Raw Normal View History

{
lib,
inputs,
snowfall-inputs,
}:
2024-03-21 15:00:36 +01:00
rec {
## Override a package's metadata
##
## ```nix
## let
## new-meta = {
## description = "My new description";
## };
## in
## lib.override-meta new-meta pkgs.hello
## ```
##
#@ Attrs -> Package -> Package
override-meta =
meta: package:
2024-03-21 15:00:36 +01:00
package.overrideAttrs (attrs: {
meta = (attrs.meta or { }) // meta;
});
}