tvl-depot/nix
Vincent Ambo 0ce396bdab feat(nix/lazy-deps): Add function to generate lazy binary dispatcher
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>
2022-05-02 23:34:55 +00:00
..
binify style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
bufCheck refactor(bufCheck): Assume bufCheck is run in depot checkout 2021-08-29 12:41:07 +00:00
buildGo fix(nix/buildGo): Use overrideAttrs to add metadata 2022-02-02 13:36:58 +00:00
buildkite refactor(ops/pipelines): Configurable GraphQL token location 2022-03-30 11:06:49 +00:00
buildLisp chore(3p/sources): Bump channels & overlays 2022-04-11 19:37:01 +00:00
buildManPages style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
drvSeqL style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
emptyDerivation style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
escapeExecline style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
getBins style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
lazy-deps feat(nix/lazy-deps): Add function to generate lazy binary dispatcher 2022-05-02 23:34:55 +00:00
mergePatch style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
netstring style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
nint style(rust): Format all Rust code with rustfmt 2022-02-08 12:06:39 +00:00
readTree refactor(readTree): deprecate meta.targets for meta.ci.targets 2022-02-07 15:13:52 +00:00
renderMarkdown style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
runExecline style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
runTestsuite style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
sparseTree style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
tag style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
tailscale style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
utils style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
writeElispBin chore(3p/sources): Bump channels and overlays 2022-04-21 16:54:07 +00:00
writeExecline style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
writers style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
writeScript style: format entire depot with nixpkgs-fmt 2022-01-31 16:11:53 +00:00
writeScriptBin refactor(nix): use our own writeScript(Bin) 2020-06-30 00:19:27 +00:00
yants docs(yants): Update josh cloning instructions 2022-02-19 11:37:00 +00:00
OWNERS chore(OWNERS): move Profpatsch up to nix/ 2021-01-01 19:03:15 +00:00