Fixup formatting

This commit is contained in:
Graham Christensen 2019-01-02 22:26:58 -05:00
parent 07a5a145a1
commit 5c04e88375
No known key found for this signature in database
GPG key ID: ACA1C1D120C83D5C

View file

@ -24,8 +24,8 @@ let
validPackageAttributes = builtins.filter validPackageAttributes = builtins.filter
(pkg: (pkg:
if (pkgs.lib.attrsets.hasAttrByPath pkg.path pkgs) then if (pkgs.lib.attrsets.hasAttrByPath pkg.path pkgs)
(if (builtins.tryEval (pkgs.lib.attrsets.attrByPath pkg.path null pkgs)).success then (if (builtins.tryEval (pkgs.lib.attrsets.attrByPath pkg.path null pkgs)).success
then true then true
else builtins.trace "Failed to access ${pkg.name} even though it exists" false) else builtins.trace "Failed to access ${pkg.name} even though it exists" false)
else builtins.trace "Failed to locate ${pkg.name}." false else builtins.trace "Failed to locate ${pkg.name}." false
@ -55,7 +55,7 @@ relevantFilenames = drv:
[ [
(builtins.unsafeGetAttrPos "maintainers" (drv.meta or {})) (builtins.unsafeGetAttrPos "maintainers" (drv.meta or {}))
(builtins.unsafeGetAttrPos "src" drv) (builtins.unsafeGetAttrPos "src" drv)
# broken because name is always set in stdenv: # broken because name is always set by stdenv:
# # A hack to make `nix-env -qa` and `nix search` ignore broken packages. # # A hack to make `nix-env -qa` and `nix search` ignore broken packages.
# # TODO(@oxij): remove this assert when something like NixOS/nix#1771 gets merged into nix. # # TODO(@oxij): remove this assert when something like NixOS/nix#1771 gets merged into nix.
# name = assert validity.handled; name + lib.optionalString # name = assert validity.handled; name + lib.optionalString
@ -76,8 +76,7 @@ attrsWithModifiedFiles = builtins.filter
listToPing = pkgs.lib.lists.flatten listToPing = pkgs.lib.lists.flatten
(builtins.map (builtins.map
(pkg: (pkg:
builtins.map builtins.map (maintainer: {
(maintainer: {
handle = maintainer.github; handle = maintainer.github;
packageName = pkg.name; packageName = pkg.name;
dueToFiles = pkg.filenames; dueToFiles = pkg.filenames;
@ -93,8 +92,7 @@ byMaintainer = pkgs.lib.lists.foldr
textForPackages = packages: textForPackages = packages:
pkgs.lib.strings.concatStringsSep ", " ( pkgs.lib.strings.concatStringsSep ", " (
builtins.map builtins.map (pkg: pkg.packageName)
(pkg: pkg.packageName)
packages); packages);
textPerMaintainer = pkgs.lib.attrsets.mapAttrs textPerMaintainer = pkgs.lib.attrsets.mapAttrs
@ -103,8 +101,7 @@ textPerMaintainer = pkgs.lib.attrsets.mapAttrs
packagesPerMaintainer = pkgs.lib.attrsets.mapAttrs packagesPerMaintainer = pkgs.lib.attrsets.mapAttrs
(maintainer: packages: (maintainer: packages:
builtins.map builtins.map (pkg: pkg.packageName)
(pkg: pkg.packageName)
packages) packages)
byMaintainer; byMaintainer;
in packagesPerMaintainer in packagesPerMaintainer