HomePhabricator
Diffusion Comm 6f8a14fa59f2

[Nix] Cache PATH between nix develop invocations

Description

[Nix] Cache PATH between nix develop invocations

Summary:
For certain environments such as XCode, it would be nice to be able
to pull in the correct version of tools needed for building native
dependencies.

Have nix write the PATH to a file, so we can source it later.

https://linear.app/comm/issue/ENG-1950

Test Plan:

# trigger `nix develop`
nix develop --command true

cat ~/.cache/comm/path
# should show `export PATH=...`

source ~/.cache/comm/path
protoc --version # should be 3.15.8

Reviewers: atul, varun, abosh, O1 Nix

Reviewed By: atul, O1 Nix

Subscribers: ashoat, tomek

Differential Revision: https://phab.comm.dev/D5319

Details

Provenance
jonAuthored on Oct 7 2022, 3:04 PM
Reviewer
Restricted Owners Package
Differential Revision
D5319: [Nix] Cache PATH between nix develop invocations
Parents
rCOMM1187b6bf021e: [Nix] Add terraform to development shell
Branches
Unknown
Tags
Unknown