about summary refs log tree commit diff
path: root/nix/lazy-deps (follow)
AgeCommit message (Collapse)AuthorFilesLines
2023-04-24 r/6106 feat(nix/lazy-deps): add override pattern for depsVincent Ambo1-50/+52
Introduces a `.overrideDeps` attribute with which additional tools can be supplied. This works like `.override` in nixpkgs. Change-Id: I69a009b51f7f073a2d030eda5e3b5310e0f8e883 Reviewed-on: https://cl.tvl.fyi/c/depot/+/8491 Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2022-12-26 r/5488 feat(nix/lazy-deps): add passthru.devShellzimbatm1-0/+6
Allows to easily convert a lazy-deps into a nix-shell compatible derivation. Change-Id: I65a0609642f12e0d00658c69cc394a73dddccd16 Reviewed-on: https://cl.tvl.fyi/c/depot/+/5855 Tested-by: BuildkiteCI Reviewed-by: tazjin <tazjin@tvl.su>
2022-12-26 r/5487 refactor(nix/lazy-deps): use runCommandzimbatm1-29/+37
writeTextFile is nice, but not flexible enough to allow the passthru argument needed for a follow-up change. Change-Id: I4f0cffd0f29b2c06b0155101d3806c9c5745c37a Reviewed-on: https://cl.tvl.fyi/c/depot/+/5854 Tested-by: BuildkiteCI Reviewed-by: tazjin <tazjin@tvl.su>
2022-05-02 r/3996 feat(nix/lazy-deps): Add function to generate lazy binary dispatcherVincent Ambo1-0/+75
There is a reoccuring problem in readTree-type repositories that use nix-shell, where evaluation of the full set of dependencies that should be made available to users takes a noticeable amount of time, slowing down operations when `direnv` is involved. In depot, we have so far fixed this by maintaining a manual `//bin` directory which contains a set of symlinks to a central dispatch script that can dispatch to various tools in depot lazily. This script can instead be generated ad-hoc by Nix (pretty fast if we can make assumptions like `git` and `nix-build` existing on user's machines already) and added to $PATH. The function introduced in this commit implements the logic for that. The structure of the script is based on the existing `//bin/__dispatch`. This does not yet switch depot's envrc to use this new method of installing dependencies lazily. Change-Id: I92efcd9bb6aa51aa2709ad910a464e9dac97ee89 Reviewed-on: https://cl.tvl.fyi/c/depot/+/5512 Tested-by: BuildkiteCI Reviewed-by: ezemtsov <eugene.zemtsov@gmail.com>