···11#!/usr/bin/env bash
22# the shebang is ignored, but nice for editors
3344-if type -P lorri &>/dev/null; then
55- eval "$(lorri direnv)"
66-else
77- echo 'while direnv evaluated .envrc, could not find the command "lorri" [https://github.com/nix-community/lorri]'
88- use flake
44+if ! has nix_direnv_version || ! nix_direnv_version 3.1.0; then
55+ echo 'While direnv evaluated .envrc, could not find nix-direnv or version is too old [https://github.com/nix-community/nix-direnv]' >&2
66+ echo 'Will use regular flake mode instead' >&2
97fi
88+99+use flake