Skip to content

Commit

Permalink
Upgrade PHP version in use to PHP 8.3
Browse files Browse the repository at this point in the history
  • Loading branch information
ronilaukkarinen committed Feb 25, 2024
1 parent 76527df commit da668f6
Show file tree
Hide file tree
Showing 7 changed files with 62 additions and 34 deletions.
8 changes: 2 additions & 6 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,25 +24,21 @@ jobs:
- name: Setup PHP with Xdebug 2.x
uses: shivammathur/setup-php@v2
with:
php-version: '7.4'
php-version: '8.3'
coverage: xdebug2

- name: Set up PHPCS and WordPress-Coding-Standards
uses: php-actions/composer@v6
env:
COMPOSER: "composer.json"
with:
php_version: "7.4"
php_version: "8.3"
version: "2.3.7"
args: "--ignore-platform-reqs --optimize-autoloader"

- name: Run PHP_CodeSniffer
run: |
vendor/bin/phpcs -p . --extensions=php --ignore=vendor,node_modules,src,js,css,sass --standard=phpcs.xml
- name: Test for PHP8.3 compatibility
run: |
vendor/bin/phpcs -p . --extensions=php --ignore=vendor,node_modules,src,js,css,sass --standard=PHPCompatibility --runtime-set testVersion 8.3
- name: Test PHP for syntax errors
run: find -L . -name '*.php' -print0 | xargs -0 -n 1 -P 4 php -l
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
* Fix accessibility strings always getting english versions if set to be translated via polylang
* Merge pull request #212 from digitoimistodude/dependabot/npm_and_yarn/ip-2.0.1
* Add unit tests for PHPCompatibility
* Upgrade PHP version in use to PHP 8.3
* Require PHP 8.3

### 9.3.6: 2024-01-10

Expand Down
2 changes: 1 addition & 1 deletion bin/tasks/additions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ echo "${YELLOW}Generating default README.md...${TXTRESET}"

NEWEST_AIR_VERSION="9.3.6"
NEWEST_WORDPRESS_VERSION="6.4.2"
NEWEST_PHP_VERSION="7.4"
NEWEST_PHP_VERSION="8.3"
CURRENT_DATE=$(LC_TIME=en_US date '+%d %b %Y' |tr ' ' '_');
echo "# ${PROJECT_NAME}
![based_on_air_version ${NEWEST_AIR_VERSION}_](https://img.shields.io/badge/based_on_air_version-${NEWEST_AIR_VERSION}_-brightgreen.svg?style=flat-square) ![project_created ${CURRENT_DATE}](https://img.shields.io/badge/project_created-${CURRENT_DATE}-blue.svg?style=flat-square) ![Tested_up_to WordPress_${NEWEST_WORDPRESS_VERSION}](https://img.shields.io/badge/Tested_up_to-WordPress_${NEWEST_WORDPRESS_VERSION}-blue.svg?style=flat-square) ![Compatible_with PHP_${NEWEST_PHP_VERSION}](https://img.shields.io/badge/Compatible_with-PHP_${NEWEST_PHP_VERSION}-green.svg?style=flat-square)
Expand Down
22 changes: 11 additions & 11 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"config": {
"allow-plugins": {
"dealerdirect/phpcodesniffer-composer-installer": true
}
},
"require-dev": {
"wp-coding-standards/wpcs": "^2.3.0",
"phpcompatibility/php-compatibility": "*",
"phpcsstandards/phpcsutils": "^1.0",
"squizlabs/php_codesniffer": "*",
"phpcsstandards/phpcsextra": "^1.2.0"
"config": {
"allow-plugins": {
"dealerdirect/phpcodesniffer-composer-installer": true
}
},
"require-dev": {
"wp-coding-standards/wpcs": "^2.3.0",
"phpcompatibility/php-compatibility": "dev-develop",
"phpcsstandards/phpcsutils": "^1.0",
"squizlabs/php_codesniffer": "*",
"phpcsstandards/phpcsextra": "^1.2.0"
}
}
58 changes: 44 additions & 14 deletions composer.lock

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

2 changes: 1 addition & 1 deletion phpcs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,6 @@
</rule>

<!-- Include sniffs for PHP cross-version compatibility. -->
<config name="testVersion" value="7.0-99.0"/>
<config name="testVersion" value="8.3-"/>
<rule ref="PHPCompatibility"/>
</ruleset>
2 changes: 1 addition & 1 deletion style.css
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ If you see this, contact the site admin.
@since 2016-01-28
Tested up to: 6.4.2
Requires PHP: 7.4
Requires PHP: 8.3
License: MIT License
License URI: LICENSE
Text Domain: air-light
Expand Down

0 comments on commit da668f6

Please sign in to comment.