18 Oct 2021 |
@gytis-ivaskevicius:matrix.org | here are several syntaxes that i managed to think of | 05:53:43 |
@gytis-ivaskevicius:matrix.org | * { abc }: {
a1 = let
a = 123;
in {
b = 123;
};
a2 = let inherit (builtins) mapAttrs; in {
b = 123;
};
a3 = abc: let
xyz = 123;
in {
abc = 123;
};
a4 = let x = 5; in {
y = x;
};
a5 = let x = 5; in x + 5;
a5 = let
x = 5;
in if x == t then 10 else null;
a6 = obj: {
x = 5;
} // obj;
}
| 05:54:51 |
David Arnold (blaggacao) | I have to pick which kettle to put on the stove. Out of principle, I'm agnostic to whatever formatting as long as it's canonical. Hence, I'd have to leave that discussion to others. 😆 | 12:52:37 |
David Arnold (blaggacao) | Otoh, https://discourse.nixos.org/t/introducing-peerix-share-your-nix-store-between-your-computers/15544 is an interesting project for DevOps. And if it will be using the purpoted IANA registered nix-cacje specific multicast ipv6, it might even be rock solid. | 12:53:47 |
David Arnold (blaggacao) | * Otoh, https://discourse.nixos.org/t/introducing-peerix-share-your-nix-store-between-your-computers/15544 is an interesting project for DevOp
s. And if it will be using the purpoted IANA registered nix-cacje specific multicast ipv6, it might even be rock solid. | 12:53:57 |
David Arnold (blaggacao) | * Otoh, https://discourse.nixos.org/t/introducing-peerix-share-your-nix-store-between-your-computers/15544 is an interesting project for DevOs. And if it will be using the purpoted IANA registered nix-cacje specific multicast ipv6, it might even be rock solid. | 12:54:03 |
David Arnold (blaggacao) | I also want to hint your attention at https://github.com/NixOS/nix/pull/5403 for any non-nixos config management need that you might have. I'm somewhat sceptical to the tendency to wrap everything into NixOS (not nix !). NixOS is not a great datacenter(-aware) operating system. No wonder as it hasn't been designed for it. | 12:57:02 |
@gytis-ivaskevicius:matrix.org | In reply to @blaggacao:matrix.org I have to pick which kettle to put on the stove. Out of principle, I'm agnostic to whatever formatting as long as it's canonical. Hence, I'd have to leave that discussion to others. 😆 what a polically correct answer | 12:57:32 |
David Arnold (blaggacao) | So that PR will ultimately allow to just json-schema type-validate your data. | 12:58:05 |
@gytis-ivaskevicius:matrix.org | oh nice | 12:58:27 |
David Arnold (blaggacao) | * Otoh, https://discourse.nixos.org/t/introducing-peerix-share-your-nix-store-between-your-computers/15544 is an interesting project for DevOs. And if it will be using the purpoted IANA registered nix-cache specific multicast ipv6, it might even be rock solid. | 12:59:01 |
@gytis-ivaskevicius:matrix.org | this is not compatible with existing modules system by the looks of things? | 12:59:23 |
David Arnold (blaggacao) | No, it is purely a compatibility layer to the json schema (industry) standard. | 12:59:59 |
David Arnold (blaggacao) | ("standing on the shoulders of giants", and such) | 13:00:31 |
@gytis-ivaskevicius:matrix.org | would be nice to be able to turn it into module system of sorts | 13:01:05 |
@gytis-ivaskevicius:matrix.org | i guess it is already a module system on its own, just without definitions | 13:01:24 |
@gytis-ivaskevicius:matrix.org | right and there is none overwrites magic | 13:01:57 |
@gytis-ivaskevicius:matrix.org | the first thought that poped into my mind is light weight modules system for stuff like stdenv.mkDerivation | 13:02:21 |
David Arnold (blaggacao) | divnix/data-merge attemts to bridge the gap to the module system, by implementing array merge strategies in a mini DSL that only lives on the RHS. (No need for additional spec or a specifically prepared LHS) | 13:02:29 |
David Arnold (blaggacao) | https://discourse.nixos.org/t/nix-data-merge-mini-dsl-with-array-merge-semantics/15540 | 13:03:30 |
David Arnold (blaggacao) | (a hastily / badly written anouncement of divnix/data-merge ) | 13:03:54 |
David Arnold (blaggacao) | * Otoh, https://discourse.nixos.org/t/introducing-peerix-share-your-nix-store-between-your-computers/15544 is an interesting project for DevOS. And if it will be using the purpoted IANA registered nix-cache specific multicast ipv6, it might even be rock solid. | 13:10:52 |
| @meccine:matrix.org joined the room. | 17:36:41 |
kamadorueda | The simpler the better, I really like that | 22:45:06 |
@timdeh:matrix.org | I'd be interested to analyze it's formal worst case complexity in comparison to the module system 🤔 | 23:27:45 |
David Arnold (blaggacao) | In reply to @timdeh:matrix.org I'd be interested to analyze it's formal worst case complexity in comparison to the module system 🤔 It is monotonistic both, in general, and in the use of a mental "+" operator. | 23:52:00 |
David Arnold (blaggacao) | It can support branching and merging of branches. | 23:52:21 |
David Arnold (blaggacao) | My feeling is it should never be more complex than git. | 23:52:42 |
David Arnold (blaggacao) | (comparing mental models) | 23:53:06 |
David Arnold (blaggacao) | In practice, though, one would seldomly want to merge branches, since branches almost exclusively represent specializations. | 23:53:48 |