2 Commits

Author SHA1 Message Date
Kevin Ledesma
159fba2b2c
Replace OpenSearch license header with Wazuh's AGPLv3 header (#184)
* Replace OpenSearch license header with Wazuh's AGPLv3 license

* Apply Wazuh's AGPLv3 license header to source code

* Replace OpenSearch contributors license header on NOTICE, build.gradle and tests files

* Update AGPL header format to the recommended by the license

* Restore copyright mention on NOTICE.txt
2024-12-16 11:56:09 +01:00
Kevin Ledesma
c38c054d7b
Implement spotless gradle pre-commit hook (#105)
* Add precommit hook definition to perform basic formatting using spotless on indexer plugins

* Add formatter configuration file for spotless tool

* Update command-manager's build.gradle to use the spotless tool

* Update spotless implementation on setup plugin

- Order build.gradle blocks
- Add spotless plugin to build.gradle
- Update formatting.gradle for both plugins

* Add formatter config for spotless on setup plugin

* Add license header validation on java files

- Add license-header.txt file with the expected content of the headers
- Update formatting.gradle on both plugins to validate the license header
- Rename buildSrc directory to formatter

* Update formatter settings

* Implement custom import order based on wazuh-indexer defined convention

* Apply format-related changes requested by spotless formatter

* Initialize a gradle base project to handle generic processes for the subprojects

- Move spotless-related configuration to main project directory
- Add pre-commit hook script to run spotlessCheck
- Add block on build.gradle to automatically apply pre-commit script into local .git dir
- Remove duplicated spotless-related code

* Apply spotless formatting to command-manager classes
2024-10-17 14:35:44 +02:00