I am writing a flake which provides
- a package
- a template which contains a flake which uses the package as an input
Iterative development of this is made difficult by the cache which avoids re-downloading a recently-downloaded flake: when you change something in the top-level flake that is needed by the template’s flake, and push the former to its public location, the latter doesn’t see the changes because of the cache.
I don’t see where something like --tarball-ttl 0
could be injected into
nix flake new -t github:whoever/whatever test-client-repo
cd test-client-repo
nix develop
I use direnv
instead of nix develop
, but using the latter and adding --tarball-ttl 0
didn’t seem to work.
Yes, this can be overcome by having the client flake point at the top-level flake on the local filesystem, during development, rather than in its publicly-accessible remote location, but
- Having to change the source back and forth between development and production versions is irritating and error-prone.
- It does weaken the verification feedback, as you’re not testing what the clients are currently seeing.
How can I force the direnv
/ nix develop
step to download the latest version of the provider flake, rather than reusing a cached download?