Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lorri init .envrc: fall back to use nix #64

Open
Profpatsch opened this issue Aug 10, 2021 · 4 comments
Open

lorri init .envrc: fall back to use nix #64

Profpatsch opened this issue Aug 10, 2021 · 4 comments

Comments

@Profpatsch
Copy link
Collaborator

Profpatsch commented Aug 10, 2021

A trivial improvement, the default .envrc should check whether lorri is installed and if not fall back to the direnv-native use nix.

@SuperSandro2000
Copy link
Member

Like this?

if has lorri; then
  eval "$(lorri direnv)"
else
  use nix
fi

@Profpatsch
Copy link
Collaborator Author

yeah, with type lorri >/dev/null I guess

@SuperSandro2000
Copy link
Member

yeah, with type lorri >/dev/null I guess

That would need to be type -P lorri &>/dev/null.

@chisui
Copy link
Contributor

chisui commented Jan 7, 2022

Maybe also include a link to lorri in the fallback case?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants