From acab143050eb8c01506f502130a9514811256b16 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Friedrich=20Dreyer?= Date: Fri, 13 May 2022 11:16:40 +0000 Subject: [PATCH] use command -v instead of which MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jörn Friedrich Dreyer --- .bingo/Variables.mk | 2 +- Makefile | 2 +- extensions/app-provider/Makefile | 2 +- extensions/app-registry/Makefile | 2 +- extensions/audit/Makefile | 2 +- extensions/auth-basic/Makefile | 2 +- extensions/auth-bearer/Makefile | 2 +- extensions/auth-machine/Makefile | 2 +- extensions/frontend/Makefile | 2 +- extensions/gateway/Makefile | 2 +- extensions/graph-explorer/Makefile | 2 +- extensions/graph/Makefile | 2 +- extensions/groups/Makefile | 2 +- extensions/idm/Makefile | 2 +- extensions/idp/Makefile | 2 +- extensions/nats/Makefile | 2 +- extensions/notifications/Makefile | 2 +- extensions/ocdav/Makefile | 2 +- extensions/ocs/Makefile | 2 +- extensions/proxy/Makefile | 2 +- extensions/settings/Makefile | 2 +- extensions/sharing/Makefile | 2 +- extensions/storage-publiclink/Makefile | 2 +- extensions/storage-shares/Makefile | 2 +- extensions/storage-system/Makefile | 2 +- extensions/storage-users/Makefile | 2 +- extensions/store/Makefile | 2 +- extensions/thumbnails/Makefile | 2 +- extensions/users/Makefile | 2 +- extensions/web/Makefile | 2 +- extensions/webdav/Makefile | 2 +- ocis-pkg/Makefile | 2 +- ocis/Makefile | 2 +- 33 files changed, 33 insertions(+), 33 deletions(-) diff --git a/.bingo/Variables.mk b/.bingo/Variables.mk index cd90d103da..01e058ce9b 100644 --- a/.bingo/Variables.mk +++ b/.bingo/Variables.mk @@ -3,7 +3,7 @@ BINGO_DIR := $(dir $(lastword $(MAKEFILE_LIST))) GOPATH ?= $(shell go env GOPATH) GOBIN ?= $(firstword $(subst :, ,${GOPATH}))/bin -GO ?= $(shell which go) +GO ?= $(shell command -v go) # Below generated variables ensure that every time a tool under each variable is invoked, the correct version # will be used; reinstalling only if needed. diff --git a/Makefile b/Makefile index 212458e4ba..6b8059ea2f 100644 --- a/Makefile +++ b/Makefile @@ -55,7 +55,7 @@ PHP_CODEBEAUTIFIER=vendor-bin/php_codesniffer/vendor/bin/phpcbf PHAN=php -d zend.enable_gc=0 vendor-bin/phan/vendor/bin/phan PHPSTAN=php -d zend.enable_gc=0 vendor-bin/phpstan/vendor/bin/phpstan -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include .bingo/Variables.mk endif diff --git a/extensions/app-provider/Makefile b/extensions/app-provider/Makefile index 54cdae4059..eaf545ffa1 100644 --- a/extensions/app-provider/Makefile +++ b/extensions/app-provider/Makefile @@ -4,7 +4,7 @@ NAME := app-provider include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/app-registry/Makefile b/extensions/app-registry/Makefile index 8097c27d96..95586b00ca 100644 --- a/extensions/app-registry/Makefile +++ b/extensions/app-registry/Makefile @@ -4,7 +4,7 @@ NAME := app-registry include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/audit/Makefile b/extensions/audit/Makefile index 522b7bfcbd..8813d06921 100644 --- a/extensions/audit/Makefile +++ b/extensions/audit/Makefile @@ -4,7 +4,7 @@ NAME := audit include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/auth-basic/Makefile b/extensions/auth-basic/Makefile index a87c8190d6..8335c0531c 100644 --- a/extensions/auth-basic/Makefile +++ b/extensions/auth-basic/Makefile @@ -4,7 +4,7 @@ NAME := auth-basic include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/auth-bearer/Makefile b/extensions/auth-bearer/Makefile index cd958c461e..d778d8c835 100644 --- a/extensions/auth-bearer/Makefile +++ b/extensions/auth-bearer/Makefile @@ -4,7 +4,7 @@ NAME := auth-bearer include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/auth-machine/Makefile b/extensions/auth-machine/Makefile index e53ab3cbec..66bf34f0a3 100644 --- a/extensions/auth-machine/Makefile +++ b/extensions/auth-machine/Makefile @@ -4,7 +4,7 @@ NAME := auth-machine include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/frontend/Makefile b/extensions/frontend/Makefile index d44b3161df..b818323b17 100644 --- a/extensions/frontend/Makefile +++ b/extensions/frontend/Makefile @@ -4,7 +4,7 @@ NAME := frontend include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/gateway/Makefile b/extensions/gateway/Makefile index f1130a590f..240f960782 100644 --- a/extensions/gateway/Makefile +++ b/extensions/gateway/Makefile @@ -4,7 +4,7 @@ NAME := gateway include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/graph-explorer/Makefile b/extensions/graph-explorer/Makefile index e83211bd58..08bb5da469 100644 --- a/extensions/graph-explorer/Makefile +++ b/extensions/graph-explorer/Makefile @@ -4,7 +4,7 @@ NAME := graph-explorer include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/graph/Makefile b/extensions/graph/Makefile index df59c1a1d6..67ad0d888d 100644 --- a/extensions/graph/Makefile +++ b/extensions/graph/Makefile @@ -4,7 +4,7 @@ NAME := graph include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/groups/Makefile b/extensions/groups/Makefile index 2f439211d3..952dc2023c 100644 --- a/extensions/groups/Makefile +++ b/extensions/groups/Makefile @@ -4,7 +4,7 @@ NAME := groups include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/idm/Makefile b/extensions/idm/Makefile index 0d04550af3..0919e6831f 100644 --- a/extensions/idm/Makefile +++ b/extensions/idm/Makefile @@ -6,7 +6,7 @@ TAGS := disable_crypt include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/idp/Makefile b/extensions/idp/Makefile index 425e6fe862..3084cdde9a 100644 --- a/extensions/idp/Makefile +++ b/extensions/idp/Makefile @@ -4,7 +4,7 @@ NAME := idp include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/nats/Makefile b/extensions/nats/Makefile index 5da8c05591..e08c864838 100644 --- a/extensions/nats/Makefile +++ b/extensions/nats/Makefile @@ -4,7 +4,7 @@ NAME := nats include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/notifications/Makefile b/extensions/notifications/Makefile index 749bf8057b..2982566e5b 100644 --- a/extensions/notifications/Makefile +++ b/extensions/notifications/Makefile @@ -4,7 +4,7 @@ NAME := notifications include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/ocdav/Makefile b/extensions/ocdav/Makefile index 7fd2d03c35..6a0849d288 100644 --- a/extensions/ocdav/Makefile +++ b/extensions/ocdav/Makefile @@ -4,7 +4,7 @@ NAME := ocdav include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/ocs/Makefile b/extensions/ocs/Makefile index 51243d83fc..f739a4d226 100644 --- a/extensions/ocs/Makefile +++ b/extensions/ocs/Makefile @@ -4,7 +4,7 @@ NAME := ocs include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/proxy/Makefile b/extensions/proxy/Makefile index c53d0e35da..44e10f95e4 100644 --- a/extensions/proxy/Makefile +++ b/extensions/proxy/Makefile @@ -4,7 +4,7 @@ NAME := proxy include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/settings/Makefile b/extensions/settings/Makefile index 397bb11c3e..a0c0e4104c 100644 --- a/extensions/settings/Makefile +++ b/extensions/settings/Makefile @@ -9,7 +9,7 @@ test-acceptance-webui: ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/sharing/Makefile b/extensions/sharing/Makefile index 074fbff5df..b264915fc0 100644 --- a/extensions/sharing/Makefile +++ b/extensions/sharing/Makefile @@ -4,7 +4,7 @@ NAME := sharing include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/storage-publiclink/Makefile b/extensions/storage-publiclink/Makefile index 0ca4c96683..32f5f3b239 100644 --- a/extensions/storage-publiclink/Makefile +++ b/extensions/storage-publiclink/Makefile @@ -4,7 +4,7 @@ NAME := storage-publiclink include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/storage-shares/Makefile b/extensions/storage-shares/Makefile index 6fc69fef89..fb62e2c67d 100644 --- a/extensions/storage-shares/Makefile +++ b/extensions/storage-shares/Makefile @@ -4,7 +4,7 @@ NAME := storage-shares include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/storage-system/Makefile b/extensions/storage-system/Makefile index 2b3adb1910..b7a331a539 100644 --- a/extensions/storage-system/Makefile +++ b/extensions/storage-system/Makefile @@ -4,7 +4,7 @@ NAME := storage-system include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/storage-users/Makefile b/extensions/storage-users/Makefile index f1e9ac0ba8..d96b83590a 100644 --- a/extensions/storage-users/Makefile +++ b/extensions/storage-users/Makefile @@ -4,7 +4,7 @@ NAME := storage-users include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/store/Makefile b/extensions/store/Makefile index 70cef069dc..c56f393a12 100644 --- a/extensions/store/Makefile +++ b/extensions/store/Makefile @@ -4,7 +4,7 @@ NAME := store include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/thumbnails/Makefile b/extensions/thumbnails/Makefile index 9e2fe5df80..c95d59f9ae 100644 --- a/extensions/thumbnails/Makefile +++ b/extensions/thumbnails/Makefile @@ -4,7 +4,7 @@ NAME := thumbnails include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/users/Makefile b/extensions/users/Makefile index 1a5e7db4ec..5c8db862a1 100644 --- a/extensions/users/Makefile +++ b/extensions/users/Makefile @@ -4,7 +4,7 @@ NAME := users include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/web/Makefile b/extensions/web/Makefile index 2dfbf0ea8c..207cf3a688 100644 --- a/extensions/web/Makefile +++ b/extensions/web/Makefile @@ -5,7 +5,7 @@ WEB_ASSETS_VERSION = v5.5.0-rc.5 include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/extensions/webdav/Makefile b/extensions/webdav/Makefile index c6418420a7..7a570b955f 100644 --- a/extensions/webdav/Makefile +++ b/extensions/webdav/Makefile @@ -4,7 +4,7 @@ NAME := webdav include ../../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../../.bingo/Variables.mk endif diff --git a/ocis-pkg/Makefile b/ocis-pkg/Makefile index af35a8664a..7a820fe133 100644 --- a/ocis-pkg/Makefile +++ b/ocis-pkg/Makefile @@ -4,7 +4,7 @@ NAME := ocis-pkg include ../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../.bingo/Variables.mk endif diff --git a/ocis/Makefile b/ocis/Makefile index 2a35463242..687806ec1a 100644 --- a/ocis/Makefile +++ b/ocis/Makefile @@ -6,7 +6,7 @@ TAGS := disable_crypt include ../.make/recursion.mk ############ tooling ############ -ifneq (, $(shell which go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI +ifneq (, $(shell command -v go 2> /dev/null)) # suppress `command not found warnings` for non go targets in CI include ../.bingo/Variables.mk GOARCH := $(shell go env GOARCH) endif