Description
This issue is automatically created based on existing pull request: #31166: Adjust .editorconfig to correct the automatic formatting of db_schema_whitelist.json files
Since the .editorconfig file was changed to use two spaces for json files, this leads to problems with db_schema_whitelist.json files. All schemas are generated by the cli setup:db-declaration:generate-whitelist command and put json content formatted by the json_decode function with JSON_PRETTY_PRINT constant. This mechanism displays an indent of 4 spaces and does not add a new line at the bottom of the file. But when we change our file db_schema.xml and run setup:db-declaration:generate-whitelist cli command, it updates the contents of the db_schema_whitelist.json file, and when we opened it in the IDE, the .editorconfig add a new line at the bottom and we can't delete it, because it is always adding at the end on saving the file.
Preconditions
Magento 2.4-develop
Related Pull Requests
Steps to reproduce
- Open any db_schema_whitelist.json file in PhpStorm
- And run Reformat Code
- Press Ctrl+S to save file
Actual result
The code has been refactored and a new line added at the end
Expected result
The code is not formatted. A "No lines changed, content is properly formated" message appears
"No lines changed, content is properly formated"
Metadata
Metadata
Assignees
Labels
Type
Projects
Status