Dendritic Nix - Community-driven Nix distribution based on the Dendritic pattern.

Add example of extending an aspect

+21
+21
dev/elm/src/Results.elm
··· 105 105 106 106 classesCount = 107 107 Dict.values aspectClassMap |> List.concatMap identity |> List.Extra.unique |> List.length |> String.fromInt 108 + 109 + firstAspect = 110 + Dict.keys aspectClassMap |> List.head |> Maybe.withDefault "virtualisation" 111 + 112 + firstClass = 113 + Dict.get firstAspect aspectClassMap |> Maybe.andThen List.head |> Maybe.withDefault "nixos" 108 114 in 109 115 [ div [] [ button [ onClick ClearFilters ] [ text "Reset filters" ] ] 110 116 , p [] ··· 118 124 , text " to include these configuration modules." 119 125 ] 120 126 , viewUsageCode model.repos 127 + , p [] 128 + [ text "Then on any flake module of yours, extend any of these aspects with your custom configs, like:" 129 + , div [] 130 + [ pre [] 131 + [ code [ class "language-nix" ] 132 + [ text ("""# modules/${aspect}.nix 133 + { 134 + # eg flake.modules.""" ++ firstClass ++ "." ++ firstAspect ++ """ = { ... }; 135 + flake.modules.${class}.${aspect} = { <your-configs> }; 136 + } 137 + """) 138 + ] 139 + ] 140 + ] 141 + ] 121 142 ] 122 143 123 144