I really like using lorri/direnv except for two problems that I have. The first is #485. The second is that it's difficult to know when the environment is ready to use.
Because lorri daemon builds the shell asynchronously, the shell environment will be updated some time after lorri detects a changed file. In the meantime, there is nothing to tell the user that their environment is stale. If the build fails, the user will continue to get the cached environment, with no indication that this is not current. It's a confusing situation.
Is it possible for lorri to somehow run shell hook functions when the lorri build status has changed? Alternatively, can lorri be configured to send a signal to a certain PID (e.g. the shell's PID). Possible states would be Started/Completed/Failed/Blocked -- something like that.
With that in place, it would be possible to make a zsh prompt that updates in realtime with the lorri status.
Target users
Everyone, but especially:
those who don't understand the internal workings of lorri
those with shell.nix files which are slow to build
Metadata
My lorri version is 1.2.0 on NixOS with services.lorri.enable = true;.
My current workaround is to monitor journalctl --user -u lorri.service -f or just disable the systemd service and run lorri watch instead.
Feature description
I really like using lorri/direnv except for two problems that I have. The first is #485. The second is that it's difficult to know when the environment is ready to use.
Because lorri daemon builds the shell asynchronously, the shell environment will be updated some time after lorri detects a changed file. In the meantime, there is nothing to tell the user that their environment is stale. If the build fails, the user will continue to get the cached environment, with no indication that this is not current. It's a confusing situation.
Is it possible for lorri to somehow run shell hook functions when the lorri build status has changed? Alternatively, can lorri be configured to send a signal to a certain PID (e.g. the shell's PID). Possible states would be Started/Completed/Failed/Blocked -- something like that.
With that in place, it would be possible to make a zsh prompt that updates in realtime with the lorri status.
Target users
Everyone, but especially:
Metadata
My lorri version is 1.2.0 on NixOS with
services.lorri.enable = true;
. My current workaround is to monitorjournalctl --user -u lorri.service -f
or just disable the systemd service and runlorri watch
instead.