Skip to content

Modernize TYPO3 Extension Metadata Handling#214

Merged
froemken merged 16 commits intomainfrom
sfRepairPhpCsFixerConfiguration
May 3, 2026
Merged

Modernize TYPO3 Extension Metadata Handling#214
froemken merged 16 commits intomainfrom
sfRepairPhpCsFixerConfiguration

Conversation

@froemken
Copy link
Copy Markdown
Collaborator

@froemken froemken commented May 2, 2026

Summary

This pull request modernizes TYPO3 extension metadata handling by removing the deprecated ext_emconf.php workflow and moving the relevant metadata into composer.json.

Changes

  • Removed ext_emconf.php from the project and from generated extensions.
  • Migrated extension metadata to composer.json under extra.typo3/cms.
  • Added TYPO3 package metadata, including Package.providesPackages and version.
  • Updated extension creation to generate the new composer metadata structure.
  • Updated test environment composer handling to preserve empty providesPackages as a JSON object.
  • Updated functional test fixtures to reflect the new composer.json structure.
  • Removed ext_emconf.php handling from the Extension Creator.
  • Updated Rector configuration to no longer analyze ext_emconf.php.
  • Adjusted Rector skips for fixture files where strict type declarations should not be enforced.
  • Adjusted PHP-CS-Fixer configuration for excluded directories and path resolution.
  • Cleaned up fixture files regarding strict type declarations.
  • Updated site setting array handling to filter out null and empty values.
  • Updated .gitignore rules for root files and generated directories.

Motivation

TYPO3 extension metadata is now handled through composer.json, making ext_emconf.php obsolete for this project. Removing its generation and usage reduces duplication, simplifies extension creation, and aligns the project with current TYPO3 standards.

Testing

Functional test fixtures and expected outputs were updated to match the new composer-based metadata structure. Rector and PHP-CS-Fixer configuration changes were adjusted to support the updated project layout and fixture handling.

froemken added 16 commits May 2, 2026 21:42
Ensure consistent path resolution by updating the `in()` definition in `.php-cs-fixer.dist.php`.
Add additional directories to the exclude list for clearer code analysis boundaries.
Include `declare(strict_types=1);` in all relevant PHP files within the functional test fixtures to enforce strict typing and improve code reliability.
Omit `declare(strict_types=1);` in functional test fixture PHP files to simplify the test setup and align with the intended purpose of fixtures as non-strictly typed code.
Ensure settings arrays exclude null or empty values during conversion to arrays, enhancing data cleanliness and consistency.
Update Rector configuration to exclude fixture files and `ext_emconf.php` from `SafeDeclareStrictTypesRector`, ensuring flexible handling of strict types for test-related and configuration files.
Remove generation and usage of `ext_emconf.php` files from the Extension Creator and functional test fixtures, reflecting their deprecation and ensuring alignment with modern TYPO3 standards.
Extend the `composer.json` structure within functional test fixtures to include `Package` metadata and `version` information, ensuring better compatibility with TYPO3 standards.
Remove the deprecated `ext_emconf.php` file and migrate metadata to `composer.json`, including `Package` metadata and `version`, aligning with modern TYPO3 standards.
Exclude `ext_emconf.php` from Rector's analyzed paths to align with its deprecation and removal in favor of `composer.json`.
@froemken froemken changed the title Repair php-cs-fixer configuration Streamline repository structure and refine code quality configurations May 2, 2026
@froemken froemken changed the title Streamline repository structure and refine code quality configurations Modernize TYPO3 Extension Metadata Handling May 2, 2026
@froemken froemken requested review from linawolf and simonschaufi May 2, 2026 22:20
@froemken froemken merged commit 4813e8e into main May 3, 2026
1 check passed
@froemken froemken deleted the sfRepairPhpCsFixerConfiguration branch May 3, 2026 11:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant