Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 65f509f

Browse filesBrowse files
committed
Fix mkFlakeApps and mkFlakePackages after #1993
1 parent 4dd2c11 commit 65f509f
Copy full SHA for 65f509f

File tree

Expand file treeCollapse file tree

1 file changed

+20
-18
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+20
-18
lines changed

‎lib/default.nix

Copy file name to clipboardExpand all lines: lib/default.nix
+20-18Lines changed: 20 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -424,26 +424,28 @@ in {
424424
}]) (packageNames coverageProject));
425425

426426
# Flake package names that are flat and match the cabal component names.
427-
mkFlakePackages = haskellPackages: builtins.listToAttrs (
428-
lib.concatLists (lib.mapAttrsToList (packageName: package:
429-
builtins.groupBy
430-
(c: c.passthru.identifier.component-id)
431-
((lib.optional (package.components ? library) package.components.library)
432-
++ package.components.sublibs
433-
++ package.components.exes
434-
++ package.components.tests
435-
++ package.components.benchmarks)
436-
) haskellPackages));
427+
mkFlakePackages = haskellPackages:
428+
builtins.groupBy
429+
(c: c.passthru.identifier.component-id)
430+
(lib.concatMap (package:
431+
(lib.optional (package.components ? library) package.components.library) ++
432+
(lib.concatMap builtins.attrValues
433+
[ package.components.sublibs
434+
package.components.exes
435+
package.components.tests
436+
package.components.benchmarks ]))
437+
(builtins.attrValues haskellPackages));
437438

438439
# Flake package names that are flat and match the cabal component names.
439-
mkFlakeApps = haskellPackages: builtins.listToAttrs (
440-
lib.concatLists (lib.mapAttrsToList (packageName: package:
441-
builtins.groupBy
442-
(c: c.passthru.identifier.component-id)
443-
(package.components.exes
444-
++ package.components.tests
445-
++ package.components.benchmarks)
446-
) haskellPackages));
440+
mkFlakeApps = haskellPackages:
441+
builtins.groupBy
442+
(c: c.passthru.identifier.component-id)
443+
(lib.concatMap (package:
444+
(lib.concatMap builtins.attrValues
445+
[ package.components.exes
446+
package.components.tests
447+
package.components.benchmarks ]))
448+
(builtins.attrValues haskellPackages));
447449

448450
# Flatten the result of collectChecks or collectChecks' for use in flake `checks`
449451
mkFlakeChecks = allChecks: builtins.listToAttrs (

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.