Skip to content

Commit

Permalink
[CI] Header check: upgrade version to NGCI 5.0.3-82
Browse files Browse the repository at this point in the history
We've been requested to upgrade the header checker tool (Copyright check tool) to latest version.

issue: HPCINFRA-2575

Signed-off-by: Viacheslav Login <[email protected]>
  • Loading branch information
vialogi authored and AlexanderGrissik committed Sep 8, 2024
1 parent 19b4b17 commit bdaf030
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
4 changes: 3 additions & 1 deletion .ci/matrix_job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ kubernetes:

credentials:
- {credentialsId: '925b0900-e273-4042-bc7c-facaefae0727', usernameVariable: 'XLIO_COV_USER', passwordVariable: 'XLIO_COV_PASSWORD'}
- {credentialsId: 'fb735938-fa1c-4b61-b568-a7c153b4fe74', usernameVariable: 'MELLANOX_GH_USER', passwordVariable: 'MELLANOX_GH_TOKEN'}

volumes:
- {mountPath: /hpc/local/bin, hostPath: /hpc/local/bin}
Expand Down Expand Up @@ -155,7 +156,8 @@ steps:

- name: Copyrights
enable: ${do_copyrights}
run: env WORKSPACE=$PWD COMPILE_DOCA=false COMPILE_DPCP=false ./contrib/jenkins_tests/copyrights.sh
credentialsId: 'fb735938-fa1c-4b61-b568-a7c153b4fe74'
run: env WORKSPACE=$PWD COMPILE_DOCA=false COMPILE_DPCP=false GITHUB_TOKEN=$MELLANOX_GH_TOKEN ./contrib/jenkins_tests/copyrights.sh
containerSelector:
- "{name: 'header-check', category: 'tool', variant: 1}"
agentSelector:
Expand Down
2 changes: 1 addition & 1 deletion contrib/jenkins_tests/copyright-check-map.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ general:
- ".*src/core/config_parser.*"
- ".*src/core/config_scanner\\.c"

nbu-open-source:
bsd:
include:
- ".*"
exclude:
Expand Down
7 changes: 6 additions & 1 deletion contrib/jenkins_tests/copyrights.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,12 @@ if [ ! -d "$WORKSPACE" ]; then
exit 1
fi

cpp_files=' "extensions": [".c", ".cc", ".cpp", "c++", ".h", ".hpp", ".cs", ".l", ".y"],'
if [[ -z $GITHUB_TOKEN ]]; then
echo "ERROR: GITHUB_TOKEN variable is empty"
exit 1
fi

cpp_files=' "extensions": [".c", ".cc", ".cpp", "c++", ".h", ".hpp", ".cs", ".inl", ".l", ".y"],'
sed -i "s/.*\"extensions\": \[\"\.c\".*/$cpp_files/g" /opt/nvidia/ProjectConfig/header-types.json

cat /opt/nvidia/ProjectConfig/header-types.json
Expand Down

0 comments on commit bdaf030

Please sign in to comment.