Skip to content

Commit

Permalink
[FAB-5282] - fix license headers
Browse files Browse the repository at this point in the history
Running "make license" fails with error reporting to replace license
headers in following files:

orderer/multichain/manager.go
orderer/multichain/manager_test.go

This commit replaces Apache license header with SPDX indentifier.
In addition extended skip list of files to check for SPDX license
identfier with *.txt files (similar to *.rst).

Change-Id: I03aa60464befa853a8542dea5716362b390775af
Signed-off-by: Artem Barger <bartem@il.ibm.com>
  • Loading branch information
C0rWin committed Jul 12, 2017
1 parent f56a82e commit ef359a7
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 27 deletions.
15 changes: 2 additions & 13 deletions orderer/multichain/manager.go
Original file line number Diff line number Diff line change
@@ -1,19 +1,8 @@
/*
Copyright IBM Corp. 2016 All Rights Reserved.
Copyright IBM Corp. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
SPDX-License-Identifier: Apache-2.0
*/

package multichain

import (
Expand Down
14 changes: 2 additions & 12 deletions orderer/multichain/manager_test.go
Original file line number Diff line number Diff line change
@@ -1,17 +1,7 @@
/*
Copyright IBM Corp. 2016 All Rights Reserved.
Copyright IBM Corp. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
SPDX-License-Identifier: Apache-2.0
*/

package multichain
Expand Down
4 changes: 2 additions & 2 deletions scripts/check_license.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@
#

CHECK=$(git diff --name-only HEAD * | grep -v .png$ | grep -v .rst$ | grep -v .git \
| grep -v .md$ | grep -v ^vendor/ | grep -v ^build/ | grep -v .pb.go$ | sort -u)
| grep -v .md$ | grep -v ^vendor/ | grep -v ^build/ | grep -v .pb.go$ | grep -v .txt | sort -u)

if [[ -z "$CHECK" ]]; then
CHECK=$(git diff-tree --no-commit-id --name-only -r $(git log -2 \
--pretty=format:"%h") | grep -v .png$ | grep -v .rst$ | grep -v .git \
| grep -v .md$ | grep -v ^vendor/ | grep -v ^build/ | grep -v .pb.go$ | sort -u)
| grep -v .md$ | grep -v ^vendor/ | grep -v ^build/ | grep -v .pb.go$ | grep -v .txt | sort -u)
fi

echo "Checking committed files for SPDX-License-Identifier headers ..."
Expand Down

0 comments on commit ef359a7

Please sign in to comment.