[ci] license-header.sh: add file exclusion capability
All checks were successful
eden-license / license-header (pull_request) Successful in 23s
All checks were successful
eden-license / license-header (pull_request) Successful in 23s
Signed-off-by: crueter <crueter@eden-emu.dev>
This commit is contained in:
parent
2832fea64b
commit
8db82e55f9
1 changed files with 8 additions and 2 deletions
|
@ -3,6 +3,12 @@
|
|||
# SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
# specify full path if dupes may exist
|
||||
EXCLUDE_FILES="CPM.cmake CPMUtil.cmake GetSCMRev.cmake"
|
||||
EXCLUDE_FILES=$(sed "s/ /\\\\|/g" <<< "$EXCLUDE_FILES")
|
||||
|
||||
echo $EXCLUDE_FILES
|
||||
|
||||
COPYRIGHT_YEAR="2025"
|
||||
COPYRIGHT_OWNER="Eden Emulator Project"
|
||||
COPYRIGHT_LICENSE="GPL-3.0-or-later"
|
||||
|
@ -49,8 +55,8 @@ if git diff --quiet "$BASE"..HEAD; then
|
|||
echo "license-header.sh: No commits on this branch different from master."
|
||||
exit 0
|
||||
fi
|
||||
FILES=$(git diff --name-only "$BASE")
|
||||
|
||||
FILES=$(git diff --name-only "$BASE" | grep -v "$EXCLUDE_FILES")
|
||||
echo $FILES
|
||||
echo_header() {
|
||||
COMMENT_TYPE="$1"
|
||||
echo "$COMMENT_TYPE SPDX-FileCopyrightText: Copyright $COPYRIGHT_YEAR $COPYRIGHT_OWNER"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue