Commit graph

2 commits

Author SHA1 Message Date
sterni
83c8716afd chore(3p): update NixOS channels to 2021-08-30
This lets us benefit from the recent OpenSSL security-related
update [1]. Since nixos-unstable is still stuck, we temporarily
use nixos-unstable-small as our unstable channel.

Fixes necessary:

* //users/sterni/nix/char:
  Someone has decided to drop writers.writeC upstream [2],
  so we reimplement it ad-hoc using runCommandCC

[1]: https://www.openssl.org/news/secadv/20210824.txt
[2]: 982f46985e

Change-Id: Id84756e2e370296b7a27e1a3f1744f58f8fe3c47
Reviewed-on: https://cl.tvl.fyi/c/depot/+/3463
Reviewed-by: sterni <sternenseemann@systemli.org>
Reviewed-by: tazjin <mail@tazj.in>
Tested-by: BuildkiteCI
2021-08-30 17:06:40 +00:00
sterni
3b33c1bd76 feat(users/sterni/nix): add sternis nix lib
What you see here is mostly the fallout of me implementing a correct
urlencode implementation in nix for Profpatsch's blog implementation
(although they'll probably keep it at arm's length).

Where I want to go from here:

* Extend this library towards general purpose nix™, mainly by
  implementing missing interfaces which you'd still have to use
  <nixpkgs/lib> for right now. Reexposing parts of <nixpkgs/lib>
  with better naming is fine for now, at some point I'd contemplate
  making this depend on nothing outside of depot, maybe even itself
  (should be easy we only use yants for an easily replaceable check).

* Improve error messages possibly by carefully reintroducing yants. I
  originally typed essentially everything using yants, but turns out
  this can a) be dangerous when stuff you are handling throws because
  type checking means evaluating and b) has a incredible performance
  cost in some cases.

* Reexpose builtins with better naming and slightly wrapped so they
  don't unrecoverably throw in cases where a null or something would
  suffice.

Change-Id: I33ab08ca4e62dbc16b86c66c653935686e6b0e79
Reviewed-on: https://cl.tvl.fyi/c/depot/+/2541
Reviewed-by: sterni <sternenseemann@systemli.org>
Reviewed-by: Profpatsch <mail@profpatsch.de>
Tested-by: BuildkiteCI
2021-03-01 17:34:35 +00:00