From ea41838ae049817fd996ead14e040d922bb7c067 Mon Sep 17 00:00:00 2001 From: "Graham Christensen (Target)" <39596207+graham-at-target@users.noreply.github.com> Date: Tue, 16 Oct 2018 10:22:36 -0400 Subject: install script: remove unportable command check, fixup errant escape `which` isn't necessarily portable, but `command -v` is an equivalent form. Additionally, the `\'` is not necessary, as it is already quoted by `"`. --- scripts/install.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/install.in b/scripts/install.in index 26ab85ba0..7bff7b216 100644 --- a/scripts/install.in +++ b/scripts/install.in @@ -11,14 +11,14 @@ oops() { } tmpDir="$(mktemp -d -t nix-binary-tarball-unpack.XXXXXXXXXX || \ - oops "Can\'t create temporary directory for downloading the Nix binary tarball")" + oops "Can't create temporary directory for downloading the Nix binary tarball")" cleanup() { rm -rf "$tmpDir" } trap cleanup EXIT INT QUIT TERM require_util() { - type "$1" > /dev/null 2>&1 || which "$1" > /dev/null 2>&1 || + type "$1" > /dev/null 2>&1 || command -v "$1" > /dev/null 2>&1 || oops "you do not have '$1' installed, which I need to $2" } -- cgit v1.2.3