Skip to content

Commit 49b78b8

Browse files
committed
Fix searching for licenses in single-segment modules
1 parent c53ce48 commit 49b78b8

File tree

2 files changed

+207
-2
lines changed

2 files changed

+207
-2
lines changed

LICENSES/vendor/go.opencensus.io/LICENSE

Lines changed: 205 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

hack/update-vendor-licenses.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -197,14 +197,14 @@ for PACKAGE in $(go list -m -json all | jq -r .Path | sort -f); do
197197
continue
198198
fi
199199
# Skip a directory if 1) it has no files and 2) all the subdirectories contain a go.mod file.
200-
if [[ -z "$(find "${DEPS_DIR}/${PACKAGE}" -mindepth 1 -maxdepth 1 -type f)" ]]; then
200+
if [[ -z "$(find "${DEPS_DIR}/${PACKAGE}/" -mindepth 1 -maxdepth 1 -type f)" ]]; then
201201
misses_go_mod=false
202202
while read -d "" -r SUBDIR; do
203203
if [[ ! -e "${SUBDIR}/go.mod" ]]; then
204204
misses_go_mod=true
205205
break
206206
fi
207-
done < <(find "${DEPS_DIR}/${PACKAGE}" -mindepth 1 -maxdepth 1 -type d -print0)
207+
done < <(find "${DEPS_DIR}/${PACKAGE}/" -mindepth 1 -maxdepth 1 -type d -print0)
208208
if [[ $misses_go_mod = false ]]; then
209209
echo "${PACKAGE} has no files, skipping" >&2
210210
continue

0 commit comments

Comments
 (0)