From 7e35ad54c3d0da5883dd42f2352ebcce5e788a94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miloslav=20Trma=C4=8D?= Date: Wed, 5 Apr 2023 20:28:36 +0200 Subject: [PATCH] Test all files by validate-git-marks MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is simpler to do, cheap enough for our repo size, and it does not require a network access to see which files to check. And it's the last user of hack/make/.validate, which I wanted to remove in the first place. Signed-off-by: Miloslav Trmač --- hack/make/.validate | 16 ---------------- hack/make/validate-git-marks | 6 +----- 2 files changed, 1 insertion(+), 21 deletions(-) delete mode 100644 hack/make/.validate diff --git a/hack/make/.validate b/hack/make/.validate deleted file mode 100644 index e5919729..00000000 --- a/hack/make/.validate +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/bash - -if [ -z "$VALIDATE_UPSTREAM" ]; then - # this is kind of an expensive check, so let's not do this twice if we - # are running more than one validate bundlescript - - VALIDATE_REPO='https://github.com/containers/skopeo.git' - VALIDATE_BRANCH='main' - - git fetch -q "$VALIDATE_REPO" "refs/heads/$VALIDATE_BRANCH" - VALIDATE_UPSTREAM="$(git rev-parse --verify FETCH_HEAD)" - - validate_diff() { - git diff "$VALIDATE_UPSTREAM" "$@" - } -fi diff --git a/hack/make/validate-git-marks b/hack/make/validate-git-marks index daa6950e..3a118053 100755 --- a/hack/make/validate-git-marks +++ b/hack/make/validate-git-marks @@ -1,11 +1,7 @@ #!/usr/bin/env bash -source "$(dirname "$BASH_SOURCE")/.validate" - -# folders=$(find * -type d | egrep -v '^Godeps|bundles|.git') - IFS=$'\n' -files=( $(validate_diff --diff-filter=ACMR --name-only -- '*' | grep -v '^vendor/' || true) ) +files=( $(git ls-tree -r HEAD --name-only | grep -v '^vendor/' || true) ) unset IFS badFiles=()