From 7bb034a68dd683b75f945412bbfc51e724012024 Mon Sep 17 00:00:00 2001 From: Fedor Partanskiy Date: Thu, 23 Jul 2026 17:47:24 +0300 Subject: [PATCH] remove check_deps.sh Signed-off-by: Fedor Partanskiy --- Makefile | 8 +------- scripts/check_deps.sh | 28 ---------------------------- 2 files changed, 1 insertion(+), 35 deletions(-) delete mode 100755 scripts/check_deps.sh diff --git a/Makefile b/Makefile index d1511416517..f9f9d9fd3b4 100644 --- a/Makefile +++ b/Makefile @@ -8,7 +8,6 @@ # # - all (default) - builds all targets and runs all non-integration tests/checks # - basic-checks - performs basic checks like license, spelling, trailing spaces and linter -# - check-deps - check for vendored dependencies that are no longer used # - checks - runs all non-integration tests/checks # - clean-all - superset of 'clean' that also removes persistent state # - clean - cleans the build area @@ -189,15 +188,10 @@ profile: export JOB_TYPE=PROFILE ## Runs unit tests for all packages in coverpro profile: unit-test # Runs unit tests for all packages in coverprofile mode (slow) .PHONY: linter -linter: check-deps gotool.goimports gotool.gofumpt gotool.staticcheck ## Runs all code checks +linter: gotool.goimports gotool.gofumpt gotool.staticcheck ## Runs all code checks @echo "LINT: Running code checks.." ./scripts/golinter.sh -.PHONY: check-deps -check-deps: ## Check for vendored dependencies that are no longer used - @echo "DEP: Checking for dependency issues.." - ./scripts/check_deps.sh - .PHONY: check-metrics-docs check-metrics-doc: gotool.gendoc ## Check for outdated reference documentation @echo "METRICS: Checking for outdated reference documentation.." diff --git a/scripts/check_deps.sh b/scripts/check_deps.sh deleted file mode 100755 index 115280e01be..00000000000 --- a/scripts/check_deps.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/bash - -# Copyright IBM Corp All Rights Reserved. -# -# SPDX-License-Identifier: Apache-2.0 - -set -euo pipefail - -# create temporary directory for go.mod and clean it -# up when the script exists. -dep_tempdir="$(mktemp -d "$(basename "$0")"-XXXXX)" -trap 'rm -rf "$dep_tempdir"' EXIT - -# copy go.mod and go.sum to the temporary directory we created -fabric_dir="$(cd "$(dirname "$0")/.." && pwd)" -cp "${fabric_dir}/go.mod" "${dep_tempdir}/" -cp "${fabric_dir}/go.sum" "${dep_tempdir}/" - -# check if we have unused requirements -go mod tidy -modfile="${dep_tempdir}/go.mod" - -for f in go.mod go.sum; do - if ! diff -q "${fabric_dir}/$f" "${dep_tempdir}/$f"; then - echo "It appears $f is stale. Please run 'go mod tidy' and 'go mod vendor'." - diff -u "${fabric_dir}/$f" "${dep_tempdir}/$f" - exit 1 - fi -done