Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/license-header-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ jobs:
- name: license-header-check
uses: NVIDIA/spark-rapids-common/license-header-check@main
with:
check_main: true
included_file_patterns: |
*.yml,
*Dockerfile*,
Expand Down
9 changes: 7 additions & 2 deletions license-header-check/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ inputs:
description: "excluded file pattern"
required: false
type: string
check_main:
description: "check main branch or not"
required: false
type: boolean
default: false

runs:
using: "composite"
Expand All @@ -36,8 +41,8 @@ runs:
CURRENT_YEAR=$(date +%Y)
LICENSE_PATTERN="Copyright \(c\) .*?${CURRENT_YEAR},? NVIDIA CORPORATION."

# Skip for merge to main PR
if [[ "${{ github.event.pull_request.base.ref }}" == "main" ]]; then
# Skip check for main branch when check_main == false
if [[ "${{ inputs.check_main }}" == "false" && "${{ github.event.pull_request.base.ref }}" == "main" ]]; then
echo "Skip this check for Merge to main PR."
exit 0
fi
Expand Down
Loading