[scripts] check for flake.nix
All checks were successful
Evaluate Hydra Jobs / eval-hydra-jobs (push) Successful in 4m15s

This commit is contained in:
ahtlon
2025-01-18 20:39:16 +01:00
parent d242562544
commit 850070f987
2 changed files with 32 additions and 4 deletions

View File

@@ -1,5 +1,4 @@
set -o errexit
set -o nounset
set -o pipefail
if [ $# -lt 2 ]; then
@@ -9,6 +8,21 @@ if [ $# -lt 2 ]; then
exit 1
fi
if [ ! -e flake.nix ]
then
echo "flake.nix not found. Searching down."
while [ ! -e flake.nix ]
do
if [ $PWD = "/" ]
then
echo "Found root. Aborting."
exit 1
else
cd ..
fi
done
fi
hostname=$1
ipaddress=$2