Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable PHP 8.1 Features with Backward Compatibility #43

Open
simbig opened this issue Dec 7, 2024 · 0 comments
Open

Enable PHP 8.1 Features with Backward Compatibility #43

simbig opened this issue Dec 7, 2024 · 0 comments

Comments

@simbig
Copy link
Contributor

simbig commented Dec 7, 2024

Is your feature request related to a problem? Please describe.

Currently, phputils supports PHP ^8 but doesn't fully utilize its features due to compatibility with PHP ^7.4.

Describe the solution you'd like

To enable the use of PHP ^8 features while maintaining backward compatibility with PHP 7.4, I'd propose implementing a strategy similar to the one outlined in this blog post: https://tomasvotruba.com/blog/how-to-release-php-81-and-72-package-in-the-same-repository/ and done in this repo: https://github.com/TomasVotruba/cognitive-complexity/blob/main/.github/workflows/downgraded_release.yaml

This approach involves:

  • Maintaining a Single Codebase: Continue developing in a single repository.
  • Downgrading for PHP 7.4 Releases: Implement a build process to downgrade the codebase and dependencies to PHP 7.4 for specific releases.

Describe alternatives you've considered

Keeping the current setup without full PHP ^8 utilization.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant