diff --git a/.github/actions/support-package-metadata/create-metadata-dir.sh b/.github/actions/support-package-metadata/create-metadata-dir.sh index c38bc10830..bdb9a25876 100755 --- a/.github/actions/support-package-metadata/create-metadata-dir.sh +++ b/.github/actions/support-package-metadata/create-metadata-dir.sh @@ -6,7 +6,10 @@ for version_dir in /tmp/support-packages/metadata/collector-versions/*; do version="$(basename "$version_dir")" git checkout "${version}" - cp "${GITHUB_WORKSPACE}/kernel-modules/MODULE_VERSION" "${version_dir}/MODULE_VERSION" + module_version_file="${GITHUB_WORKSPACE}/kernel-modules/MODULE_VERSION" + if [[ -f "${module_version_file}" ]]; then + cp "${module_version_file}" "${version_dir}/MODULE_VERSION" + fi done git checkout "${BRANCH_NAME}" diff --git a/kernel-modules/support-packages/03-group-by-module-version.sh b/kernel-modules/support-packages/03-group-by-module-version.sh index 3645c5b5c1..d0ffecd06e 100755 --- a/kernel-modules/support-packages/03-group-by-module-version.sh +++ b/kernel-modules/support-packages/03-group-by-module-version.sh @@ -18,6 +18,7 @@ MD_DIR="$1" for version_dir in "${MD_DIR}/collector-versions"/*; do [[ -d "$version_dir" ]] || continue + [[ -f "${version_dir}/MODULE_VERSION" ]] || continue module_version="$(< "${version_dir}/MODULE_VERSION")"