!UUqahLbShAYkkrXmKs:matrix.org

DevOS

31 Members
Seeking help and geeking out together on https://github.com/divnix/devos & https://github.com/divnix/digga10 Servers

Load older messages


SenderMessageTime
28 Sep 2021
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.org*lastModified should probably be in human readable format15:44:03
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orghold on,im dumb. Forgot to remove 'owner' and 'repo' 😀16:07:01
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.org *

Not sure what exactly was proposed in that unofficial roadmap but just now I played around with toml format and this is what I managed to define:

[github.NixOS.nixpkgs.release-21.05]
lastModified = 1632660378
narHash = 'sha256-sjA8eQlnyDjDLyAyq3XlJmN0nqW0ftl/pb7VnMg86L0='
rev = '31ffc50c571e6683e9ecc9dbcbd4a8e9914b4497'


16:07:13
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.org *

Not sure what exactly was proposed in that unofficial roadmap but just now I played around with toml format and this is what I managed to define:

[github.NixOS.nixpkgs.release-21.05]
lastModified = 1979-05-27T07:32:00-08:00
narHash = 'sha256-sjA8eQlnyDjDLyAyq3XlJmN0nqW0ftl/pb7VnMg86L0='
rev = '31ffc50c571e6683e9ecc9dbcbd4a8e9914b4497'

16:08:37
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orgAh, there is another issue with this toml16:10:24
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orgthere is no way to define custom arguments like dir16:10:38
@yusdacra:nixos.dev@yusdacra:nixos.dev
In reply to @gytis-ivaskevicius:matrix.org
Not perfect, also I am not sure how I feel about file being editable AND automagically modifiable
Isn't the point of a lockfile to not be modified?
16:24:16
@yusdacra:nixos.dev@yusdacra:nixos.dev
In reply to @gytis-ivaskevicius:matrix.org
Not perfect, also I am not sure how I feel about file being editable AND automagically modifiable
* Isn't the point of a lockfile to not be modified manually?
16:24:52
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orgwhat we are thinking of is not just a lockfile16:25:04
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orga file that would act as a lockfile AND inputs definition16:25:16
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orgso you could avoid defining inputs in flake.nix16:25:27
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.organd the whole avoidance of defining inputs in flake.nix is due to its limitations16:26:00
@yusdacra:nixos.dev@yusdacra:nixos.devAh so basically to avoid redefining inputs in both places16:29:06
@yusdacra:nixos.dev@yusdacra:nixos.devThat sounds like it'd be interesting16:29:39
@yusdacra:nixos.dev@yusdacra:nixos.dev How would you "lock" an input to a certain revision in the example TOML? With flake.nix you can specify the revision in flake.nix and it will be locked, but if you change the rev field here doing a nix flake update would still update it right? 16:31:43
@yusdacra:nixos.dev@yusdacra:nixos.dev * How would you lock an input to a certain revision in the example TOML? With flake.nix you can specify the revision in flake.nix and it will be locked, but if you change the rev field here doing a nix flake update would still update it right? 16:31:51
@timdeh:matrix.org@timdeh:matrix.org I was imagining that the inputs in flake.nix are kinda redundant and that cli args could just as easily and remove and modify the lock file directly. So instead of inputs.someflake.url = "github:yada/yada" in the flake.nix you could do something like `nix flake add someflake github:yara/yada" 17:59:41
@timdeh:matrix.org@timdeh:matrix.org * I was imagining that the inputs in flake.nix are kinda redundant and that cli args could just as easily add, remove and modify the lock file directly. So instead of inputs.someflake.url = "github:yada/yada" in the flake.nix you could do something like `nix flake add someflake github:yara/yada" 17:59:56
@timdeh:matrix.org@timdeh:matrix.org * I was imagining that the inputs in flake.nix are kinda redundant and that cli args could just as easily add, remove and modify the lock file directly. So instead of inputs.someflake.url = "github:yada/yada" in the flake.nix you could do something like nix flake add someflake github:yara/yada" 18:00:05
@yusdacra:nixos.dev@yusdacra:nixos.devhmm i see18:10:49
@yusdacra:nixos.dev@yusdacra:nixos.devThat sounds nice TBH18:11:32
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.org
In reply to @timdeh:matrix.org
I was imagining that the inputs in flake.nix are kinda redundant and that cli args could just as easily add, remove and modify the lock file directly. So instead of inputs.someflake.url = "github:yada/yada" in the flake.nix you could do something like nix flake add someflake github:yara/yada"
I'd rather have inputs explicitly defined in some file instead of such lock file editing
18:43:07
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orgbut that might be just me18:43:12
@timdeh:matrix.org@timdeh:matrix.orgfor what purpose though? If you could have a command list them out nicely, you can view the lockfile manually, and you can even explore the inputs in a repl. What does the explicit listing give us?18:44:12
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.org I definetelly realize that something like nix flake show could show us all the inputs or even how they follow each other, its just that i would prefer it being managed declaratively 18:53:36
@pachumicchu:myrdd.infoPacman99To me the advantage is readability and clarity. When I look at someone else's flake online I can see what they depend on immediately. The lockfile and json in general is harder to read.18:53:39
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orgjust a personal preference18:53:42
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orgto be fair you probably dont care all that much when it comes to inputs of some random flakes18:54:17
@gytis-ivaskevicius:matrix.org@gytis-ivaskevicius:matrix.orgor atleast I dont18:54:24
@pachumicchu:myrdd.infoPacman99And yeah you can def just use nix flake show, but I feel like you should be able to get a summary of the flake without the nix cli18:54:35

Show newer messages


Back to Room ListRoom Version: 6