mirror of
https://github.com/prometheus/node_exporter.git
synced 2024-11-13 17:14:23 -08:00
Use POSIX "command" instead of non-standard "which"
This commit is contained in:
parent
e681dcc296
commit
92ea3e1599
|
@ -100,10 +100,10 @@ EOF
|
||||||
trap finish EXIT
|
trap finish EXIT
|
||||||
|
|
||||||
get() {
|
get() {
|
||||||
if which curl > /dev/null 2>&1
|
if command -v curl > /dev/null 2>&1
|
||||||
then
|
then
|
||||||
curl -s -f "$@"
|
curl -s -f "$@"
|
||||||
elif which wget > /dev/null 2>&1
|
elif command -v wget > /dev/null 2>&1
|
||||||
then
|
then
|
||||||
wget -O - "$@"
|
wget -O - "$@"
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue