Skip to content

Commit

Permalink
Enabled automated license header checks
Browse files Browse the repository at this point in the history
1. Added the SPDX license header to the files with missing license headers.
2. Re-enabled the 'licenseHeaders' check in the build.gradle file.
3. Added an IntelliJ copyright profile to auto-generate the SPDX license header.
4. Updated the .gitignore file.

Signed-off-by: Ketan Verma <ketan9495@gmail.com>
  • Loading branch information
ketanv3 committed Jun 12, 2021
1 parent 3dd0717 commit bc483fe
Show file tree
Hide file tree
Showing 7 changed files with 75 additions and 12 deletions.
32 changes: 32 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Compiled class file
*.class

# Log file
*.log

# BlueJ files
*.ctxt

# Mobile Tools for Java (J2ME)
.mtj.tmp/

# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
hs_err_pid*

# IntelliJ files
.idea/*
*.iml
*.ipr
*.iws
build-idea/
out/

# Include Copyright template for IntelliJ
!.idea/copyright

# Gradle files
.gradle
build

# OSX files
.DS_Store
6 changes: 6 additions & 0 deletions .idea/copyright/SPDX_ALv2.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions .idea/copyright/profiles_settings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,7 @@ tasks.named("integTest").configure {
it.dependsOn(project.tasks.named("bundlePlugin"))
}

//TODO enable license headers
licenseHeaders.enabled = false
licenseHeaders.enabled = true
dependencyLicenses.enabled = false
thirdPartyAudit.enabled = false
validateNebulaPom.enabled = false
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
/*
* SPDX-License-Identifier: Apache-2.0
*
* The OpenSearch Contributors require contributions made to
* this file be licensed under the Apache-2.0 license or a
* compatible open source license.
*
* Modifications Copyright OpenSearch Contributors. See
* GitHub history for details.
*/

package org.opensearch.search.asynchronous.settings;

import org.opensearch.common.settings.Setting;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
/*
* SPDX-License-Identifier: Apache-2.0
*
* The OpenSearch Contributors require contributions made to
* this file be licensed under the Apache-2.0 license or a
* compatible open source license.
*
* Modifications Copyright OpenSearch Contributors. See
* GitHub history for details.
*/

package org.opensearch.search.asynchronous.settings;

import org.junit.Before;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
/*
* SPDX-License-Identifier: Apache-2.0
*
* The OpenSearch Contributors require contributions made to
* this file be licensed under the Apache-2.0 license or a
* compatible open source license.
*
* Modifications Copyright OpenSearch Contributors. See
* GitHub history for details.
*/

/*
* Copyright 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
Expand All @@ -12,16 +23,6 @@
* express or implied. See the License for the specific language governing
* permissions and limitations under the License.
*/
/*
* SPDX-License-Identifier: Apache-2.0
*
* The OpenSearch Contributors require contributions made to
* this file be licensed under the Apache-2.0 license or a
* compatible open source license.
*
* Modifications Copyright OpenSearch Contributors. See
* GitHub history for details.
*/

package org.opensearch.search.asynchronous.utils;

Expand Down

0 comments on commit bc483fe

Please sign in to comment.