The Nix Hour

The Nix Hour is a weekly beginner-oriented improvised QA-style lecture on Nix, hosted by Tweag. Here you can bring your questions and we'll answer them with more context, examples, alternatives, tradeoffs and related topics. These meetings are open for anybody to join, but also recorded and uploaded to the Tweag YouTube channel. For more information check out https://discourse.nixos.org/t/the-nix-hour-a-weekly-nix-qa-lecture-by-tweag/22767

Curated by: Tweag by Modus Create (81 videos)


Currently Playing: The Nix Hour #16 [parametrized module system options]

The Nix Hour is a weekly beginner-oriented improvised Q&A-style lecture on Nix, where you can bring your questions and we'll answer them with more context, examples, alternatives, tradeoffs and related topics. Feel free to ask questions using the live chat, or even ask questions directly by joining the meeting: https://meet.jit.si/nix-hour. Alternatively ask questions ahead of time by opening an issue in https://github.com/tweag/nix-hour For more information and updates, check out https://discourse.nixos.org/t/the-nix-hour-a-weekly-nix-qa-lecture-by-tweag/22767 00:00 Intro and looking at the question 01:17 How users.extraUsers is defined and why it exists alongside users.users 10:02 Why double users.users 11:00 Declaring, defining and using your own module system options 17:32 The attrsOf option type 22:29 The submodule option type 31:05 Problem with declaring options in submodule definitions 34:10 Looking at the option type documentation 35:24 The useful pattern of combining attrsOf and submodule 42:48 Accessing the attribute name in the submodule 44:52 Parametrized options in the manual 47:12 Extending parametrized options, merging types 52:28 Implementing extended parametrized option behavior 54:12 Trying to build the system, takes too long though 56:00 Recommendation: Use attrsOf instead of listOf for improved overridability


Tracks in this Playlist