diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 581aa1f..7a49116 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -57,4 +57,4 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - run: mvn -e -B org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.projectKey=green-code-initiative_ecoCode-php + run: mvn -e -B org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.projectKey=green-code-initiative_creedengo-php diff --git a/.github/workflows/build_container.yml b/.github/workflows/build_container.yml index faf3e09..041f291 100644 --- a/.github/workflows/build_container.yml +++ b/.github/workflows/build_container.yml @@ -13,9 +13,9 @@ on: # - main env: - IMAGE_NAME: sonarqube-ecocode-php + IMAGE_NAME: sonarqube-creedengo-php IMAGES: | - ghcr.io/${{ github.repository_owner }}/sonarqube-ecocode-php + ghcr.io/${{ github.repository_owner }}/sonarqube-creedengo-php jobs: Build: diff --git a/.github/workflows/manual_release.yml b/.github/workflows/manual_release.yml index c0c7b15..903c676 100644 --- a/.github/workflows/manual_release.yml +++ b/.github/workflows/manual_release.yml @@ -62,8 +62,8 @@ jobs: id: export_jar_files uses: actions/upload-artifact@v3 with: - name: ecocode-plugins - path: target/ecocode-php-plugin-${{ env.LAST_TAG }}.jar + name: creedengo-plugins + path: target/creedengo-php-plugin-${{ env.LAST_TAG }}.jar - name: Export LAST_TAG id: export_last_tag run: echo "last_tag=${{ env.LAST_TAG }}" >> $GITHUB_OUTPUT @@ -80,8 +80,8 @@ jobs: id: import_jar_files uses: actions/download-artifact@v3 with: - name: ecocode-plugins - path: target/ecocode-php-plugin-${{ needs.build.outputs.last_tag }}.jar + name: creedengo-plugins + path: target/creedengo-php-plugin-${{ needs.build.outputs.last_tag }}.jar - name: Upload Release Asset - PHP Plugin id: upload-release-asset uses: actions/upload-release-asset@v1 @@ -89,7 +89,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: upload_url: ${{ needs.build.outputs.upload_url }} - asset_path: target/ecocode-php-plugin-${{ needs.build.outputs.last_tag }}.jar - asset_name: ecocode-php-plugin-${{ needs.build.outputs.last_tag }}.jar + asset_path: target/creedengo-php-plugin-${{ needs.build.outputs.last_tag }}.jar + asset_name: creedengo-php-plugin-${{ needs.build.outputs.last_tag }}.jar asset_content_type: application/zip diff --git a/.github/workflows/tag_release.yml b/.github/workflows/tag_release.yml index 8a31066..7881584 100644 --- a/.github/workflows/tag_release.yml +++ b/.github/workflows/tag_release.yml @@ -50,7 +50,7 @@ jobs: id: export_jar_files uses: actions/upload-artifact@v3 with: - name: ecocode-plugins + name: creedengo-plugins path: target - name: Export UPLOAD_URL id: export_upload_url @@ -65,7 +65,7 @@ jobs: id: import_jar_files uses: actions/download-artifact@v3 with: - name: ecocode-plugins + name: creedengo-plugins path: target - name: Upload Release Asset - PHP Plugin id: upload-release-asset @@ -74,6 +74,6 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: upload_url: ${{needs.build.outputs.upload_url}} - asset_path: target/ecocode-php-plugin-${{ github.ref_name }}.jar - asset_name: ecocode-php-plugin-${{ github.ref_name }}.jar + asset_path: target/creedengo-php-plugin-${{ github.ref_name }}.jar + asset_name: creedengo-php-plugin-${{ github.ref_name }}.jar asset_content_type: application/zip diff --git a/CHANGELOG.md b/CHANGELOG.md index 5f87387..cb0d9f9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,7 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed -- [#34](https://github.com/green-code-initiative/ecoCode-php/issues/34) Add test to ensure all Rules are registered +- [#34](https://github.com/green-code-initiative/creedengo-php/issues/34) Add test to ensure all Rules are registered ### Deleted @@ -26,7 +26,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed - upgrade docker system -- [#30](https://github.com/green-code-initiative/ecoCode-php/issues/30) Upgrade dependencies to latest ones - technical +- [#30](https://github.com/green-code-initiative/creedengo-php/issues/30) Upgrade dependencies to latest ones - technical incompatibilities for SonarQube before 9.9 version - clean unit test files (to have less other issues) @@ -34,18 +34,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed -- [#28](https://github.com/green-code-initiative/ecoCode-php/issues/28) Add support for SonarQube 10.6.0 +- [#28](https://github.com/green-code-initiative/creedengo-php/issues/28) Add support for SonarQube 10.6.0 ## [1.4.3] - 2024-05-15 ### Added -- [#20](https://github.com/green-code-initiative/ecoCode-php/issues/20) Add support for SonarQube 10.4 " +- [#20](https://github.com/green-code-initiative/creedengo-php/issues/20) Add support for SonarQube 10.4 " DownloadOnlyWhenRequired" feature ### Changed -- [#23](https://github.com/green-code-initiative/ecoCode-php/issues/23) deprecation of EC22 rule for PHP (waiting for +- [#23](https://github.com/green-code-initiative/creedengo-php/issues/23) deprecation of EC22 rule for PHP (waiting for measurement to prove it) - check Sonarqube 10.5.1 compatibility + update docker files and README.md @@ -53,7 +53,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed -- [#17](https://github.com/green-code-initiative/ecoCode-php/issues/17) Correction of error with deprecated EC34 rule +- [#17](https://github.com/green-code-initiative/creedengo-php/issues/17) Correction of error with deprecated EC34 rule - Update ecocode-rules-specifications to 1.4.7 ## [1.4.1] - 2024-01-06 @@ -64,13 +64,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed -- [#9](https://github.com/green-code-initiative/ecoCode-php/pull/9) Upgrade licence system and licence headers of Java +- [#9](https://github.com/green-code-initiative/creedengo-php/pull/9) Upgrade licence system and licence headers of Java files -- [#10](https://github.com/green-code-initiative/ecoCode-php/pull/10) Adding EC35 rule : EC35 rule replaces EC34 with a +- [#10](https://github.com/green-code-initiative/creedengo-php/pull/10) Adding EC35 rule : EC35 rule replaces EC34 with a specific use case ("file not found" specific) -- [#13](https://github.com/green-code-initiative/ecoCode-php/issues/13) Add build number to manifest -- [#12](https://github.com/green-code-initiative/ecoCode-php/issues/12) Fix unit tests execution with Maven -- Update ecocode-rules-specifications to 1.4.6 +- [#13](https://github.com/green-code-initiative/creedengo-php/issues/13) Add build number to manifest +- [#12](https://github.com/green-code-initiative/creedengo-php/issues/12) Fix unit tests execution with Maven +- Update ecoCode-rules-specifications to 1.4.6 - README.md upgrade : docker test environment ## [1.4.0] - 2023-08-08 @@ -78,15 +78,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added - PHP rules moved from `ecoCode` repository to current repository -- [#121](https://github.com/green-code-initiative/ecoCode/issues/121) new PHP rule : Multiple if-else statement + +- [#121](https://github.com/green-code-initiative/creedengo-rules-specifications/issues/121) new PHP rule : Multiple if-else statement + refactoring implementation -- [#205](https://github.com/green-code-initiative/ecoCode/issues/205) compatibility with SonarQube 10.1 +- [#205](https://github.com/green-code-initiative/creedengo-rules-specifications/issues/205) compatibility with SonarQube 10.1 ## Comparison list -[unreleased](https://github.com/green-code-initiative/ecoCode-php/compare/1.4.4...HEAD) -[1.4.4](https://github.com/green-code-initiative/ecoCode-php/compare/1.4.3...1.4.4) -[1.4.3](https://github.com/green-code-initiative/ecoCode-php/compare/1.4.2...1.4.3) -[1.4.2](https://github.com/green-code-initiative/ecoCode-php/compare/1.4.1...1.4.2) -[1.4.1](https://github.com/green-code-initiative/ecoCode-php/compare/1.4.0...1.4.1) -[1.4.0](https://github.com/green-code-initiative/ecoCode-php/releases/tag/1.4.0) +[unreleased](https://github.com/green-code-initiative/creedengo-php/compare/1.4.4...HEAD) +[1.4.4](https://github.com/green-code-initiative/creedengo-php/compare/1.4.3...1.4.4) +[1.4.3](https://github.com/green-code-initiative/creedengo-php/compare/1.4.2...1.4.3) +[1.4.2](https://github.com/green-code-initiative/creedengo-php/compare/1.4.1...1.4.2) +[1.4.1](https://github.com/green-code-initiative/creedengo-php/compare/1.4.0...1.4.1) +[1.4.0](https://github.com/green-code-initiative/creedengo-php/releases/tag/1.4.0) diff --git a/CODE_STYLE.md b/CODE_STYLE.md index 86b0ab3..c46ab38 100644 --- a/CODE_STYLE.md +++ b/CODE_STYLE.md @@ -1 +1 @@ -Please read common [CODE_STYLE.md](https://github.com/green-code-initiative/ecoCode-common/blob/main/doc/CODE_STYLE.md) in `ecoCode-common` repository. +Please read common [CODE_STYLE.md](https://github.com/green-code-initiative/creedengo-common/blob/main/doc/CODE_STYLE.md) in `creedengo-common` repository. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 77e81dc..aeeae91 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1 +1 @@ -Please read common [CONTRIBUTING.md](https://github.com/green-code-initiative/ecoCode-common/blob/main/doc/CONTRIBUTING.md) in `ecoCode-common` repository. +Please read common [CONTRIBUTING.md](https://github.com/green-code-initiative/creedengo-common/blob/main/doc/CONTRIBUTING.md) in `creedengo-common` repository. diff --git a/Dockerfile b/Dockerfile index 02840bc..af6645a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,14 +5,14 @@ ARG SONARQUBE_VERSION=10.6.0-community FROM maven:${MAVEN_BUILDER} AS builder -COPY . /usr/src/ecocode +COPY . /usr/src/creedengo -WORKDIR /usr/src/ecocode +WORKDIR /usr/src/creedengo COPY src src/ COPY pom.xml tool_build.sh ./ RUN ./tool_build.sh FROM sonarqube:${SONARQUBE_VERSION} -COPY --from=builder /usr/src/ecocode/target/ecocode-*.jar /opt/sonarqube/extensions/plugins/ +COPY --from=builder /usr/src/creedengo/target/creedengo-*.jar /opt/sonarqube/extensions/plugins/ USER sonarqube diff --git a/INSTALL.md b/INSTALL.md index e802cb4..f767ec3 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -1,8 +1,8 @@ Common installation notes / requirements ======================================== -Please read common [INSTALL.md](https://github.com/green-code-initiative/ecoCode-common/blob/main/doc/INSTALL.md) -in `ecoCode-common` repository. Please follow the specific guides below for additional information on installing the +Please read common [INSTALL.md](https://github.com/green-code-initiative/creedengo-common/blob/main/doc/INSTALL.md) +in `creedengo-common` repository. Please follow the specific guides below for additional information on installing the desired plugins. Special points for Standard plugins @@ -14,7 +14,7 @@ Project structure Here is a preview of project tree : ```txt -ecoCode-php # Root directory +creedengo-php # Root directory | +--src # source directory | diff --git a/README.md b/README.md index 8e3a8e7..2515b0e 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,12 @@ -EcoCode-php +creedengo-php =========== -_ecoCode_ is a collective project aiming to reduce environmental footprint of software at the code level. The goal of +_creedengo_ is a collective project aiming to reduce environmental footprint of software at the code level. The goal of the project is to provide a list of static code analyzers to highlight code structures that may have a negative ecological impact: energy and resources over-consumption, "fatware", shortening terminals' lifespan, etc. -_ecoCode_ is based on evolving catalogs -of [good practices](https://github.com/green-code-initiative/ecoCode/blob/main/docs/rules), for various technologies. +_creedengo_ is based on evolving catalogs +of [good practices](https://github.com/green-code-initiative/creedengo-rules-specifications/blob/main/docs/rules), for various technologies. This SonarQube plugin then implements these catalogs as rules for scanning your PHP projects. @@ -14,14 +14,14 @@ SonarQube plugin then implements these catalogs as rules for scanning your PHP p > refer to the contribution section. [![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0) -[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg)](https://github.com/green-code-initiative/ecoCode-common/blob/main/doc/CODE_OF_CONDUCT.md) +[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg)](https://github.com/green-code-initiative/creedengo-common/blob/main/doc/CODE_OF_CONDUCT.md) 🌿 SonarQube Plugins ------------------- -This plugin is part of the ecoCode project.\ +This plugin is part of the creedengo project.\ You can find a list of all our other plugins in -the [ecoCode repository](https://github.com/green-code-initiative/ecoCode#-sonarqube-plugins) +the [creedengo repository](https://github.com/green-code-initiative/creedengo#-sonarqube-plugins) 🚀 Getting Started ------------------ @@ -31,34 +31,34 @@ You can give a try with a one command docker : ```sh docker run -ti --rm \ -p 9000:9000 \ - --name sonarqube-ecocode-php ghcr.io/green-code-initiative/sonarqube-ecocode-php:latest + --name sonarqube-creedengo-php ghcr.io/green-code-initiative/sonarqube-creedengo-php:latest ``` or (with logs and data locally stored) : ```sh docker run -ti --rm \ - -v sq_ecocode_logs:/opt/sonarqube/logs \ - -v sq_ecocode_data:/opt/sonarqube/data \ + -v sq_creedengo_logs:/opt/sonarqube/logs \ + -v sq_creedengo_data:/opt/sonarqube/data \ -p 9000:9000 \ - --name sonarqube-ecocode-php ghcr.io/green-code-initiative/sonarqube-ecocode-php:latest + --name sonarqube-creedengo-php ghcr.io/green-code-initiative/sonarqube-creedengo-php:latest ``` -... and configure local SonarQube (security config and quality profile : see [configuration](https://github.com/green-code-initiative/ecoCode-common/blob/main/doc/INSTALL.md#configuration-sonarqube) for more details). +... and configure local SonarQube (security config and quality profile : see [configuration](https://github.com/green-code-initiative/creedengo-common/blob/main/doc/INSTALL.md#configuration-sonarqube) for more details). -To install other `ecocode` plugins, you can also : +To install other `creedengo` plugins, you can also : - download each plugin separatly and copy the plugin (jar file) to `$SONAR_INSTALL_DIR/extensions/plugins` and restart SonarQube. -- install different ecocode plugins with Marketplace (inside admin panel of SonarQube) +- install different creedengo plugins with Marketplace (inside admin panel of SonarQube) -Then you can use PHP test project repository to test the environment : see README.md of [PHP test project](https://github.com/green-code-initiative/ecoCode-php-test-project) +Then you can use PHP test project repository to test the environment : see README.md of [PHP test project](https://github.com/green-code-initiative/creedengo-php-test-project) -Finally, you can directly use a [all-in-one docker-compose](https://github.com/green-code-initiative/ecoCode-common/blob/main/doc/INSTALL.md#start-sonarqube-if-first-time) +Finally, you can directly use a [all-in-one docker-compose](https://github.com/green-code-initiative/creedengo-common/blob/main/doc/INSTALL.md#start-sonarqube-if-first-time) 🛒 Distribution ------------------ -Ready to use binaries are available [from GitHub](https://github.com/green-code-initiative/ecoCode-php/releases). +Ready to use binaries are available [from GitHub](https://github.com/green-code-initiative/creedengo-php/releases). 🧩 Compatibility ----------------- @@ -69,17 +69,17 @@ Ready to use binaries are available [from GitHub](https://github.com/green-code- | 1.5.+ | 9.9.+ to 10.6.0 | 17 | > Compatibility table of versions lower than 1.4.+ are available from the -> main [ecoCode repository](https://github.com/green-code-initiative/ecoCode#-plugins-version-compatibility). +> main [creedengo repository](https://github.com/green-code-initiative/creedengo-rules-specifications#-plugins-version-compatibility). 🤝 Contribution --------------- -check [ecoCode repository](https://github.com/green-code-initiative/ecoCode#-contribution) +check [creedengo repository](https://github.com/green-code-initiative/creedengo-rules-specifications#-contribution) 🤓 Main contributors -------------------- -check [ecoCode repository](https://github.com/green-code-initiative/ecoCode#-main-contributors) +check [creedengo repository](https://github.com/green-code-initiative/creedengo-rules-specifications#-main-contributors) Links ----- diff --git a/RULES.md b/RULES.md index 13bf375..29d1d91 100644 --- a/RULES.md +++ b/RULES.md @@ -1 +1 @@ -Please read [RULES.md](https://github.com/green-code-initiative/ecoCode/blob/main/RULES.md) in `ecoCode` repository. +Please read [RULES.md](https://github.com/green-code-initiative/creedengo-rules-specifications/blob/main/RULES.md) in `creedengo` repository. diff --git a/TODOs_DDC.md b/TODOs_DDC.md index d3e81c9..38e7fe1 100644 --- a/TODOs_DDC.md +++ b/TODOs_DDC.md @@ -3,7 +3,7 @@ TODOS dev DDC actions vues en séance weekly-meeting : -- ecoCode-android : nettoyer packages (suite au release) +- creedengo-android : nettoyer packages (suite au release) actions vues perso : diff --git a/docker-compose.yml b/docker-compose.yml index 1329e65..78bbe71 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,9 +1,9 @@ -name: sonarqube_ecocode_php +name: sonarqube_creedengo_php services: sonar: build: . - container_name: sonar_ecocode_php + container_name: sonar_creedengo_php ports: - ":9000" networks: @@ -28,7 +28,7 @@ services: db: image: postgres:12 - container_name: postgresql_ecocode_php + container_name: postgresql_creedengo_php networks: - sonarnet volumes: diff --git a/pom.xml b/pom.xml index 226fd39..bf4a9ea 100644 --- a/pom.xml +++ b/pom.xml @@ -3,17 +3,17 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 - io.ecocode - ecocode-php-plugin + org.green-code-initiative + creedengo-php-plugin 1.5.2-SNAPSHOT sonar-plugin - ecoCode - PHP language + creedengo - PHP language Provides rules to reduce the environmental footprint of your PHP programs - 2023 + 2024 - https://github.com/green-code-initiative/ecoCode-php + https://github.com/green-code-initiative/creedengo-php green-code-initiative https://github.com/green-code-initiative @@ -28,15 +28,15 @@ - scm:git:https://github.com/green-code-initiative/ecocode-php - scm:git:https://github.com/green-code-initiative/ecocode-php - https://github.com/green-code-initiative/ecocode-php + scm:git:https://github.com/green-code-initiative/creedengo-php + scm:git:https://github.com/green-code-initiative/creedengo-php + https://github.com/green-code-initiative/creedengo-php HEAD GitHub - https://github.com/green-code-initiative/ecoCode-php/issues + https://github.com/green-code-initiative/creedengo-php/issues @@ -64,8 +64,8 @@ 1.23.0.740 - - 1.6.2 + + 2.0.0 3.6.0 @@ -83,8 +83,8 @@ ${project.groupId} - ecocode-rules-specifications - ${ecocode-rules-specifications.version} + creedengo-rules-specifications + ${creedengo-rules-specifications.version} php @@ -186,7 +186,7 @@ ${sonar-packaging.version} true - ecocodephp + creedengophp fr.greencodeinitiative.php.PHPPlugin true ${sonarqube.version} @@ -258,7 +258,7 @@ Green Code Initiative - https://www.ecocode.io + https://green-code-initiative.org diff --git a/src/main/java/fr/greencodeinitiative/php/PHPPlugin.java b/src/main/java/fr/greencodeinitiative/php/PHPPlugin.java index 81d6945..db89781 100644 --- a/src/main/java/fr/greencodeinitiative/php/PHPPlugin.java +++ b/src/main/java/fr/greencodeinitiative/php/PHPPlugin.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/main/java/fr/greencodeinitiative/php/PhpRuleRepository.java b/src/main/java/fr/greencodeinitiative/php/PhpRuleRepository.java index e6aec3b..c65a171 100644 --- a/src/main/java/fr/greencodeinitiative/php/PhpRuleRepository.java +++ b/src/main/java/fr/greencodeinitiative/php/PhpRuleRepository.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -41,9 +41,9 @@ public class PhpRuleRepository implements RulesDefinition, PHPCustomRuleReposito ); private static final String LANGUAGE = "php"; - private static final String NAME = "ecoCode"; - private static final String RESOURCE_BASE_PATH = "io/ecocode/rules/php"; - private static final String REPOSITORY_KEY = "ecocode-php"; + private static final String NAME = "creedengo"; + private static final String RESOURCE_BASE_PATH = "org/green-code-initiative/rules/php"; + private static final String REPOSITORY_KEY = "creedengo-php"; private final SonarRuntime sonarRuntime; diff --git a/src/main/java/fr/greencodeinitiative/php/checks/AvoidDoubleQuoteCheck.java b/src/main/java/fr/greencodeinitiative/php/checks/AvoidDoubleQuoteCheck.java index d7674e7..0549bfc 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/AvoidDoubleQuoteCheck.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/AvoidDoubleQuoteCheck.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -30,7 +30,8 @@ import org.sonar.plugins.php.api.visitors.PHPSubscriptionCheck; import org.sonarsource.analyzer.commons.annotations.DeprecatedRuleKey; -@Rule(key = "EC66") +@Rule(key = "GCI66") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC66") @DeprecatedRuleKey(repositoryKey = "gci-php", ruleKey = "S66") public class AvoidDoubleQuoteCheck extends PHPSubscriptionCheck { diff --git a/src/main/java/fr/greencodeinitiative/php/checks/AvoidFullSQLRequestCheck.java b/src/main/java/fr/greencodeinitiative/php/checks/AvoidFullSQLRequestCheck.java index 65a1abb..fb8ea27 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/AvoidFullSQLRequestCheck.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/AvoidFullSQLRequestCheck.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -28,7 +28,8 @@ import java.util.regex.Matcher; import java.util.regex.Pattern; -@Rule(key = "EC74") +@Rule(key = "GCI74") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC74") @DeprecatedRuleKey(repositoryKey = "gci-php", ruleKey = "S74") public class AvoidFullSQLRequestCheck extends PHPSubscriptionCheck { diff --git a/src/main/java/fr/greencodeinitiative/php/checks/AvoidGettingSizeCollectionInLoopCheck.java b/src/main/java/fr/greencodeinitiative/php/checks/AvoidGettingSizeCollectionInLoopCheck.java index b776b47..c3a11f4 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/AvoidGettingSizeCollectionInLoopCheck.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/AvoidGettingSizeCollectionInLoopCheck.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -27,12 +27,14 @@ import org.sonar.plugins.php.api.tree.statement.StatementTree; import org.sonar.plugins.php.api.tree.statement.WhileStatementTree; import org.sonar.plugins.php.api.visitors.PHPSubscriptionCheck; +import org.sonarsource.analyzer.commons.annotations.DeprecatedRuleKey; import java.util.Arrays; import java.util.List; import java.util.regex.Pattern; -@Rule(key = "EC3") +@Rule(key = "GCI3") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC3") public class AvoidGettingSizeCollectionInLoopCheck extends PHPSubscriptionCheck { public static final String ERROR_MESSAGE = "Avoid getting the size of the collection in the loop"; diff --git a/src/main/java/fr/greencodeinitiative/php/checks/AvoidMultipleIfElseStatementCheck.java b/src/main/java/fr/greencodeinitiative/php/checks/AvoidMultipleIfElseStatementCheck.java index 8af8ea5..2322d5f 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/AvoidMultipleIfElseStatementCheck.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/AvoidMultipleIfElseStatementCheck.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -26,13 +26,14 @@ import org.sonar.plugins.php.api.tree.expression.VariableIdentifierTree; import org.sonar.plugins.php.api.tree.statement.*; import org.sonar.plugins.php.api.visitors.PHPSubscriptionCheck; +import org.sonarsource.analyzer.commons.annotations.DeprecatedRuleKey; import java.util.HashMap; import java.util.List; import java.util.Map; /** - * FUNCTIONAL DESCRIPTION : please see ASCIIDOC description file of this rule (inside `ecocode-rules-spcifications`) + * FUNCTIONAL DESCRIPTION : please see ASCIIDOC description file of this rule (inside `creedengo-rules-spcifications`) * TECHNICAL CHOICES : * - Kind.IF_STATEMENT, Kind.ELSE_STATEMENT, Kind.ELSEIF_STATEMENT not used because it isn't possible * to keep parent references to check later if variables already used or not in parent tree @@ -40,7 +41,8 @@ * - an "ELSE" statement is considered as a second IF statement using the same variables used on previous * - IF and ELSEIF statements are considered as an IF statement */ -@Rule(key = "EC2") +@Rule(key = "GCI2") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC2") public class AvoidMultipleIfElseStatementCheck extends PHPSubscriptionCheck { public static final String ERROR_MESSAGE = "Use a switch statement instead of multiple if-else if possible"; diff --git a/src/main/java/fr/greencodeinitiative/php/checks/AvoidSQLRequestInLoopCheck.java b/src/main/java/fr/greencodeinitiative/php/checks/AvoidSQLRequestInLoopCheck.java index 6cbfe1b..af74d97 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/AvoidSQLRequestInLoopCheck.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/AvoidSQLRequestInLoopCheck.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -34,7 +34,8 @@ import org.sonar.plugins.php.api.visitors.PHPSubscriptionCheck; import org.sonarsource.analyzer.commons.annotations.DeprecatedRuleKey; -@Rule(key = "EC72") +@Rule(key = "GCI72") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC72") @DeprecatedRuleKey(repositoryKey = "gci-php", ruleKey = "S72") public class AvoidSQLRequestInLoopCheck extends PHPSubscriptionCheck { diff --git a/src/main/java/fr/greencodeinitiative/php/checks/AvoidTryCatchWithFileOpenedCheck.java b/src/main/java/fr/greencodeinitiative/php/checks/AvoidTryCatchWithFileOpenedCheck.java index 6680bb9..6c83da4 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/AvoidTryCatchWithFileOpenedCheck.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/AvoidTryCatchWithFileOpenedCheck.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -31,7 +31,8 @@ import org.sonar.plugins.php.api.visitors.PHPSubscriptionCheck; import org.sonarsource.analyzer.commons.annotations.DeprecatedRuleKey; -@Rule(key = "EC35") +@Rule(key = "GCI35") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC35") @DeprecatedRuleKey(repositoryKey = "gci-php", ruleKey = "S34") @DeprecatedRuleKey(ruleKey = "EC34") diff --git a/src/main/java/fr/greencodeinitiative/php/checks/AvoidUsingGlobalVariablesCheck.java b/src/main/java/fr/greencodeinitiative/php/checks/AvoidUsingGlobalVariablesCheck.java index 124a8b3..24b7364 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/AvoidUsingGlobalVariablesCheck.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/AvoidUsingGlobalVariablesCheck.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -24,7 +24,8 @@ import java.util.regex.Pattern; -@Rule(key = "EC4") +@Rule(key = "GCI4") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC4") @DeprecatedRuleKey(repositoryKey = "gci-php", ruleKey = "D4") public class AvoidUsingGlobalVariablesCheck extends PHPVisitorCheck { diff --git a/src/main/java/fr/greencodeinitiative/php/checks/IncrementCheck.java b/src/main/java/fr/greencodeinitiative/php/checks/IncrementCheck.java index 85efefe..76ac31f 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/IncrementCheck.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/IncrementCheck.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -26,7 +26,8 @@ import org.sonar.plugins.php.api.visitors.PHPSubscriptionCheck; import org.sonarsource.analyzer.commons.annotations.DeprecatedRuleKey; -@Rule(key = "EC67") +@Rule(key = "GCI67") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC67") @DeprecatedRuleKey(repositoryKey = "gci-php", ruleKey = "S67") public class IncrementCheck extends PHPSubscriptionCheck { diff --git a/src/main/java/fr/greencodeinitiative/php/checks/NoFunctionCallWhenDeclaringForLoop.java b/src/main/java/fr/greencodeinitiative/php/checks/NoFunctionCallWhenDeclaringForLoop.java index de9889b..f3dd204 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/NoFunctionCallWhenDeclaringForLoop.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/NoFunctionCallWhenDeclaringForLoop.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -30,7 +30,8 @@ import org.sonar.plugins.php.api.visitors.PHPSubscriptionCheck; import org.sonarsource.analyzer.commons.annotations.DeprecatedRuleKey; -@Rule(key = "EC69") +@Rule(key = "GCI69") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC69") @DeprecatedRuleKey(repositoryKey = "gci-php", ruleKey = "S69") public class NoFunctionCallWhenDeclaringForLoop extends PHPSubscriptionCheck { diff --git a/src/main/java/fr/greencodeinitiative/php/checks/UseOfMethodsForBasicOperations.java b/src/main/java/fr/greencodeinitiative/php/checks/UseOfMethodsForBasicOperations.java index 23223f5..7e54daf 100644 --- a/src/main/java/fr/greencodeinitiative/php/checks/UseOfMethodsForBasicOperations.java +++ b/src/main/java/fr/greencodeinitiative/php/checks/UseOfMethodsForBasicOperations.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -34,7 +34,8 @@ import org.sonar.plugins.php.api.visitors.PHPSubscriptionCheck; import org.sonarsource.analyzer.commons.annotations.DeprecatedRuleKey; -@Rule(key = "EC22") +@Rule(key = "GCI22") +@DeprecatedRuleKey(repositoryKey = "ecocode-php", ruleKey = "EC22") @DeprecatedRuleKey(repositoryKey = "gci-php", ruleKey = "D2") public class UseOfMethodsForBasicOperations extends PHPSubscriptionCheck { diff --git a/src/test/java/fr/greencodeinitiative/php/PhpPluginTest.java b/src/test/java/fr/greencodeinitiative/php/PhpPluginTest.java index 7f25c2a..6583691 100644 --- a/src/test/java/fr/greencodeinitiative/php/PhpPluginTest.java +++ b/src/test/java/fr/greencodeinitiative/php/PhpPluginTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/PhpRuleRepositoryTest.java b/src/test/java/fr/greencodeinitiative/php/PhpRuleRepositoryTest.java index 8f82197..d358f72 100644 --- a/src/test/java/fr/greencodeinitiative/php/PhpRuleRepositoryTest.java +++ b/src/test/java/fr/greencodeinitiative/php/PhpRuleRepositoryTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -51,9 +51,9 @@ void init() { @Test @DisplayName("Test repository metadata") void testMetadata() { - assertThat(repository.name()).isEqualTo("ecoCode"); + assertThat(repository.name()).isEqualTo("creedengo"); assertThat(repository.language()).isEqualTo("php"); - assertThat(repository.key()).isEqualTo("ecocode-php"); + assertThat(repository.key()).isEqualTo("creedengo-php"); } @Test @@ -69,11 +69,11 @@ void checkNumberRules() { } @Test - @DisplayName("All rule keys must be prefixed by 'EC'") + @DisplayName("All rule keys must be prefixed by 'GCI'") void testRuleKeyPrefix() { SoftAssertions assertions = new SoftAssertions(); repository.rules().forEach( - rule -> assertions.assertThat(rule.key()).startsWith("EC") + rule -> assertions.assertThat(rule.key()).startsWith("GCI") ); assertions.assertAll(); } diff --git a/src/test/java/fr/greencodeinitiative/php/checks/AvoidDoubleQuoteCheckTest.java b/src/test/java/fr/greencodeinitiative/php/checks/AvoidDoubleQuoteCheckTest.java index 12ed606..9eed7cf 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/AvoidDoubleQuoteCheckTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/AvoidDoubleQuoteCheckTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/checks/AvoidFullSQLRequestCheckTest.java b/src/test/java/fr/greencodeinitiative/php/checks/AvoidFullSQLRequestCheckTest.java index aee6056..70355ef 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/AvoidFullSQLRequestCheckTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/AvoidFullSQLRequestCheckTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/checks/AvoidGettingSizeCollectionInLoopTest.java b/src/test/java/fr/greencodeinitiative/php/checks/AvoidGettingSizeCollectionInLoopTest.java index 5d69449..413c1a1 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/AvoidGettingSizeCollectionInLoopTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/AvoidGettingSizeCollectionInLoopTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/checks/AvoidMultipleIfElseStatementCheckTest.java b/src/test/java/fr/greencodeinitiative/php/checks/AvoidMultipleIfElseStatementCheckTest.java index 18399cd..ff80cba 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/AvoidMultipleIfElseStatementCheckTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/AvoidMultipleIfElseStatementCheckTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/checks/AvoidSQLRequestInLoopCheckTest.java b/src/test/java/fr/greencodeinitiative/php/checks/AvoidSQLRequestInLoopCheckTest.java index b6fb3ad..c027808 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/AvoidSQLRequestInLoopCheckTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/AvoidSQLRequestInLoopCheckTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/checks/AvoidTryCatchWithFileOpenedCheckTest.java b/src/test/java/fr/greencodeinitiative/php/checks/AvoidTryCatchWithFileOpenedCheckTest.java index 12a7c05..17d7f4b 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/AvoidTryCatchWithFileOpenedCheckTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/AvoidTryCatchWithFileOpenedCheckTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/checks/AvoidUsingGlobalVariablesCheckTest.java b/src/test/java/fr/greencodeinitiative/php/checks/AvoidUsingGlobalVariablesCheckTest.java index 89f0f8f..e8b6ccb 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/AvoidUsingGlobalVariablesCheckTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/AvoidUsingGlobalVariablesCheckTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/checks/IncrementCheckTest.java b/src/test/java/fr/greencodeinitiative/php/checks/IncrementCheckTest.java index a79ad5d..9f72da7 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/IncrementCheckTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/IncrementCheckTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/checks/NoFunctionCallWhenDeclaringForLoopTest.java b/src/test/java/fr/greencodeinitiative/php/checks/NoFunctionCallWhenDeclaringForLoopTest.java index 6b11d91..1283675 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/NoFunctionCallWhenDeclaringForLoopTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/NoFunctionCallWhenDeclaringForLoopTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/src/test/java/fr/greencodeinitiative/php/checks/UseOfMethodsForBasicOperationsTest.java b/src/test/java/fr/greencodeinitiative/php/checks/UseOfMethodsForBasicOperationsTest.java index 4726108..dad3578 100644 --- a/src/test/java/fr/greencodeinitiative/php/checks/UseOfMethodsForBasicOperationsTest.java +++ b/src/test/java/fr/greencodeinitiative/php/checks/UseOfMethodsForBasicOperationsTest.java @@ -1,6 +1,6 @@ /* - * ecoCode - PHP language - Provides rules to reduce the environmental footprint of your PHP programs - * Copyright © 2023 Green Code Initiative (https://www.ecocode.io) + * creedengo - PHP language - Provides rules to reduce the environmental footprint of your PHP programs + * Copyright © 2024 Green Code Initiative (https://green-code-initiative.org) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by