!9IQChSjwSHXPPWTa:lix.systems

Lix

810 Members
Lix user channel. Feel free to discuss on-topic issues here and give each other help. For matrix.to links to the rest of the Lix channels, see: https://wiki.lix.systems/books/lix-organisation/page/matrix-rooms235 Servers

Load older messages


SenderMessageTime
14 Feb 2025
@charles:computer.surgeryCharlesand here's an example of how it can be used: https://gitlab.computer.surgery/charles/sprinkles/-/blob/charles/wip/examples/greeter.nix?ref_type=heads21:48:57
@drakon64:matrix.orgAdam Chance

there are currently zero docs
Sounds like every project I've ever started

21:49:07
@kfears:matrix.orgKFears (no longer human)Saved this fornlater, looks cool21:49:08
@drakon64:matrix.orgAdam Chance *

there are currently zero docs

Sounds like every project I've ever started

21:49:14
@charles:computer.surgeryCharles the charles/wip branch is currently blocked on this stupid bug: https://github.com/nix-community/nix-direnv/pull/549 21:49:28
@k900:0upti.meK900It's weird and cool how your thing seems to do everything in Nix21:49:36
@k900:0upti.meK900And my personal attempt at this did the exact opposite21:49:49
@charles:computer.surgeryCharlesyeah it's just regular nix code, no secret sauce21:50:11
@kfears:matrix.orgKFears (no longer human)* Saved this for later, looks cool21:50:14
@charles:computer.surgeryCharles the main nix/lib dir doesn't depend on anything, not even nixpkgs 21:50:25
@charles:computer.surgeryCharles * the main nix/lib dir doesn't depend on anything, not even nixpkgs, just builtins 21:50:33
@k900:0upti.meK900Yeah my take was to just get all the input fetching entirely outside of nix21:50:48
@k900:0upti.meK900 And then you just have a node_modules style thing 21:51:05
@charles:computer.surgeryCharlesmy idea is basically to define a sort of schema for sources/inputs/outputs, and then punt the problem of pinning dependencies to something else21:51:28
@k900:0upti.meK900I do kinda want to finish that PoC21:51:58
@charles:computer.surgeryCharles this is cool because you can use anything to manage sources: builtins.fetchGit/builtins.fetchTarball,import, npins, even flakes via flake-compat 21:52:00
@k900:0upti.meK900Because it is like21:52:01
@k900:0upti.meK900Weirdly cool21:52:03
@k900:0upti.meK900 The trick node_modules does basically works as-is on nix 21:52:27
@k900:0upti.meK900Which is very funny21:52:47
@charles:computer.surgeryCharles i don't know enough about node_modules to follow but it sounds intriguing 21:52:50
@kfears:matrix.orgKFears (no longer human)My attempt that I was working on before the void has taken my laptop was a hybrid approach, where there's a Nix part and a Rust part21:52:55
@k900:0upti.meK900
In reply to@charles:computer.surgery
i don't know enough about node_modules to follow but it sounds intriguing
The short version is that if you have libfoo that depends on libbar, you just have node_modules/libfoo/node_modules/libbar
21:53:22
@k900:0upti.meK900 And to import a dependency you just import ./node_modules/libfoo 21:53:33
@charles:computer.surgeryCharlesi see21:53:34
@k900:0upti.meK900 Which can then internally do import ./node_modules/libbar 21:53:42
@charles:computer.surgeryCharlesright21:53:51
@charles:computer.surgeryCharlesclever21:53:56
@k900:0upti.meK900And with a bit of symlink magic you can make it all resolve to basically a store21:53:59
@charles:computer.surgeryCharleswindows users probably hate it21:54:09

Show newer messages


Back to Room ListRoom Version: 10