diff --git a/.envrc b/.envrc index 78c21249..ff5ec47b 100644 --- a/.envrc +++ b/.envrc @@ -1,3 +1,5 @@ +source ./omnixrc + watch_file \ nix/modules/nixpkgs.nix \ nix/modules/rust.nix \ @@ -6,4 +8,8 @@ watch_file \ *.nix \ rust-toolchain.toml \ crates/omnix-init/registry/flake.* -use flake . + +# Dogfood our own ./omnixrc! +# This may lead to compiling omnix if the commit hasn't yet been built in CI +# But let's live with that for now. +use omnix . diff --git a/omnixrc b/omnixrc new file mode 100644 index 00000000..9332118b --- /dev/null +++ b/omnixrc @@ -0,0 +1,10 @@ +# -*- mode: sh -*- +# shellcheck shell=bash + +use_omnix() { + # TODO: Switch to nixpkgs version once we upstream + # Because, the user may not be a trusted-user leading to compilation! + nix --accept-flake-config run github:juspay/omnix health $* + + use flake $* +}