From aaa777168e84458121f9d228b29ecd0e06e8fbf9 Mon Sep 17 00:00:00 2001 From: tv Date: Wed, 24 Jun 2015 20:46:25 +0200 Subject: there can be only one nixos-query --- bin/nixos-query | 21 ++------------------- 1 file changed, 2 insertions(+), 19 deletions(-) (limited to 'bin/nixos-query') diff --git a/bin/nixos-query b/bin/nixos-query index 65b5c967..1111aead 100755 --- a/bin/nixos-query +++ b/bin/nixos-query @@ -1,21 +1,4 @@ #! /bin/sh set -euf - -host=$1 -attr=$2 - -nixpkgs=$nixpkgs_root/$host -nixos_config=$config_root/modules/$host -secrets_nix=$secrets_root/$host/nix -secrets_rsync=$secrets_root/$host/rsync - -nix-instantiate \ - -I "$nixpkgs" \ - -I nixos-config="$nixos_config" \ - -I retiolum-hosts="$retiolum_hosts" \ - -I secrets="$secrets_nix" \ - -A config."$attr" \ - '' \ - --eval \ - --json \ - | jq -r . +result=$(nix-instantiate -A config."$1" --eval --json '') +echo $result | jq -r . -- cgit v1.2.3