This repository was archived by the owner on Oct 15, 2022. It is now read-only.
Only regenerate shell_gc_root if store path changes#498
Open
leotaku wants to merge 1 commit intotarget:masterfrom
Open
Only regenerate shell_gc_root if store path changes#498leotaku wants to merge 1 commit intotarget:masterfrom
leotaku wants to merge 1 commit intotarget:masterfrom
Conversation
Currently, lorri may regenerate the shell_gc_root link to the project environments store path, even if that store path has not changed. With this commit, lorri will now check if the current and previous store paths are identical and, if so, avoid regenerating the symlink. This is especially interesting as lorri instructs direnv to watch the shell_gc_root symlink, previously causing direnv to be constantly reinvoked for some projects. If merged, this should also fix issue target#387.
Author
|
Whoops, it seems like those CI errors are out of my control... |
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Currently, lorri may regenerate the shell_gc_root link to the project
environments store path, even if that store path has not changed.
With this commit, lorri will now check if the current and previous
store paths are identical and, if so, avoid regenerating the symlink.
This is especially interesting as lorri instructs direnv to watch the
shell_gc_root symlink, previously causing direnv to be constantly
reinvoked for some projects.
If merged, this should also fix issue #387.
Closes #387.
Overview
I simply tried implementing the most obvious solution with guidance from #387. I have tested these by running the modified binary on my personal machine and with my personal projects.
Also, I am not sure if this should be classified as a feature or a fix.
Checklist
release.nix(seerelease.nixfor instructions)