!kjdutkOsheZdjqYmqp:nixos.org

Empty Room

1912 Members
400 Servers

Load older messages


SenderMessageTime
14 Jan 2025
@hellwolf:matrix.orghellwolf * https://github.com/NixOS/nixpkgs/pull/373563#discussion_r1914593287 I am not maintaining nixpkgs daily, could anyone help to explain this message to me? What made the "with" pattern undesirable and for when? 10:40:50
@niklaskorz:korz.devNiklas Korz
In reply to @hellwolf:matrix.org
https://github.com/NixOS/nixpkgs/pull/373563#discussion_r1914593287 I am not maintaining nixpkgs daily, could anyone help to explain this message to me? What made the "with" pattern undesirable and for when?
it has the same downsides that using namespace std; has in C++, if that helps
10:42:01
@toonn:matrix.orgtoonn It's been considered undesirable for about 5 years now. It's very hard to track where names came from in its presence. 10:42:11
@niklaskorz:korz.devNiklas Korz it's ok to use if you e.g. only apply it to a directly following array, such as with lib.maintainers; [ ... ] 10:42:52
@perchun:matrix.orgPerchun Pak with lib should be avoided, just with is fine 10:43:01
@hellwolf:matrix.orghellwolfalright folks. it's just that it's a lot of work for casual maintainers to keep up with this. I am interested in pushing this forward; but I totally feel it for people simply can't keep up and drop the balls.10:43:09
@toonn:matrix.orgtoonn Might also affect evaluation performance negatively because of the size of the lookup it necessitates. 10:43:21
@hellwolf:matrix.orghellwolf

with lib should be avoided, just with is fine

You mean with lib.maintainers okay>

10:43:43
@hellwolf:matrix.orghellwolf *

with lib should be avoided, just with is fine

You mean with lib.maintainers could be okay?

10:43:50
@hellwolf:matrix.orghellwolf I think saying to avoid with lib is easier to digest 10:44:01
@niklaskorz:korz.devNiklas Korz
In reply to @hellwolf:matrix.org
alright folks. it's just that it's a lot of work for casual maintainers to keep up with this. I am interested in pushing this forward; but I totally feel it for people simply can't keep up and drop the balls.
that's what reviews are for, it's not meant to be a personal attack but to raise awareness :)
10:44:09
@hellwolf:matrix.orghellwolfa linter for nixpkgs would be nice for maintainers10:44:13
@toonn:matrix.orgtoonn A much nicer pattern IMO is `let inherit (set) value; in <body>`. 10:44:17
@hellwolf:matrix.orghellwolf

that's what reviews are for, it's not meant to be a personal attack but to raise awareness :)

No, not taking as personal attack. But it's a lot of churns.

10:44:31
@hellwolf:matrix.orghellwolfLinter can help maintainer to get this right before putting it forward to people10:44:48
@hellwolf:matrix.orghellwolf* A linter can help maintainer to get this right before putting it forward to people10:44:50
@niklaskorz:korz.devNiklas Korzyeah on that I agree! is there an ongoing RFC for a nixpkgs linter?10:45:04
@hellwolf:matrix.orghellwolfformatter is great, but linter has more roles10:45:20
@niklaskorz:korz.devNiklas Korzalso because such common things would then by catched by Github Actions10:45:25
@hellwolf:matrix.orghellwolf* the current formatter is great, but linter has more roles10:45:26
@niklaskorz:korz.devNiklas Korz* also because such common things would then be by catched by Github Actions10:45:34
@niklaskorz:korz.devNiklas Korz* also because such common things would then be catched by Github Actions10:45:38
@glepage:matrix.orgGaƩtan Lepage I know that Lucas Eduardo is pretty interested in this topic. 10:45:47
@l1npengtul:matrix.orgl1npengtulIs there a way to symlink to the user's directory from a derivation?10:45:52
@k900:0upti.meK900
In reply to@l1npengtul:matrix.org
Is there a way to symlink to the user's directory from a derivation?
No
10:46:32
@k900:0upti.meK900Why>10:46:36
@niklaskorz:korz.devNiklas Korz I'd also love stdenv.mkDerivation rec to be catched by a linter... 10:46:37
@k900:0upti.meK900* Why?10:46:37
@rnhmjoj:eurofusion.eu@rnhmjoj:eurofusion.eu
In reply to @toonn:matrix.org
A much nicer pattern IMO is `let inherit (set) value; in <body>`.
for with lib;, but for with lib.maintainers it completely defeats the point
10:46:42
@l1npengtul:matrix.orgl1npengtulA binary application I'm dealing doesn't want to respect the HOME envvar. I'm assuming I have to make a FHS at this point.10:47:11

Show newer messages


Back to Room ListRoom Version: 6