Skip to content

Commit 6e1e0ce

Browse files
savilLagoja
authored andcommitted
[UX] print statement for recomputing the nixEnv (#1521)
## Summary This print-dev-env calculation may be a bit slow, so we should print a statement for the waiting user. I do this in `ensurePackagesAreInstalled`, instead of in `nix.PrintDevEnv` because otherwise we can print it 3x due to our cache misses. Note, this PR is focussed on the least-risky change for the release to improve UX for improved wait times on switching to Remove Nixpkgs mode. ## How was it tested? compiles (cherry picked from commit e008f3b)
1 parent 97f8738 commit 6e1e0ce

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

internal/impl/packages.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -234,6 +234,8 @@ func (d *Devbox) ensurePackagesAreInstalled(ctx context.Context, mode installMod
234234
}
235235

236236
// Force print-dev-env cache to be recomputed.
237+
// We may be able to remove this after improving cache hits.
238+
fmt.Fprintf(d.stderr, "Recomputing the devbox environment.\n")
237239
if _, err := d.computeNixEnv(ctx, false /*use cache*/); err != nil {
238240
return err
239241
}

0 commit comments

Comments
 (0)