vtk-m/.gitlab/ci/config/ecpci-amend-commit.sh
Kenneth Moreland 898115a410 Add copyright notice to scipts and configuration files
There are numerous scripts and configuration files defined in the CI setup
and elsewhere that were missing the copyright statement. Add more types
of files to check in the CopyrightStatement test, and update the files
with the appropriate statement.
2023-07-25 11:05:40 -06:00

27 lines
821 B
Bash
Executable File

#!/bin/bash -e
# shellcheck disable=SC2155
##=============================================================================
##
## Copyright (c) Kitware, Inc.
## All rights reserved.
## See LICENSE.txt for details.
##
## This software is distributed WITHOUT ANY WARRANTY; without even
## the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
## PURPOSE. See the above copyright notice for more information.
##
##=============================================================================
git rev-parse @ > ./ORIGINAL_COMMIT_SHA
git add ./ORIGINAL_COMMIT_SHA
readonly name="$(git show --quiet --format='%cn')"
readonly email="$(git show --quiet --format='%ce')"
git config --global user.name "$name"
git config --global user.email "$email"
git commit --amend --no-edit -a
git rev-parse @ > "$1"