-
-
Notifications
You must be signed in to change notification settings - Fork 483
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
[RFC] Revert the move of translations/ into config/ #253
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request passes validation.
@fabpot looking at the Symfony PR linked in #249, it looks like you were the one requesting this move. So can you give your mind here ? @javiereguiluz the quick merge is related to the fact that a bot is merging PRs for this repo, so it merges as soon as it gets the required approvals. |
Not having directories that depend on the project scope/dependencies at the project root level seems better to me. |
did we ever consider having both |
@ro0NL but there are at least 3 directories whose contents are not only managed by developers: assets, templates and translations. We have |
agree that's why i think we should consider having both config/ + etc/.
|
I totally disagree because of "discoverability" and "simplicity". These days we've updated tens of Symfony Docs for Symfony 4. The best thing about that was that lots of things no longer need to be explained: they are self-explanatory and that's great. If templates are stored in If templates are stored in
|
Anyway about I admit The original issue was actually asking how to replace the old Projects root dirs are already filled with a lot of directories and (.dot)files. I find this overwhelming for everyone. If we can reduce this and the disparity between projects using or not templating, translations, etc... I think we should. In any case, I agree we've done this change too fast, without any real discussion nor giving enough time for the community to speak. I'm sorry about that, I should have opened an issue first after the merge of the default path for translations. But if we revert this commit, I guess we should also update the default value for this new config option. |
Im not sure src/Resources and etc/ serve the same purpose. I wouldnt necessarily expect project tied resources to be found under src/. IMHO src/Resources would contain things required/leveraged by source code relative to ../ (i.e. src/).
Agree, claiming all root directories could make the project dir look dramatically huge. Not necessarily making it more easy to discover, as other "project related" things might root here as well.
I suggest to use both directories :) Given we cant put everything inside config/ nor inside the project root dir. etc/ === app/Resources to me, a clear upgrade path also. |
I don't think project root dirs are crowded. And if they are, we should work to reduce the useless dot files, not the real project directories. |
Ok, after thinking a bit more about this one, I think @javiereguiluz is right. Let's revert. |
👍 for revert. Still not sure we should claim all project root dirs ( Today i would do |
Ok for revert. Still not convinced this should be at the root though.
We cannot reduce the nb of dot files used in projects, we don't have the hand on it as these are required by third-party tools. |
Updating default path in symfony/symfony#25083 |
…uto) This PR was merged into the 3.4 branch. Discussion ---------- [FrameworkBundle] Update default translations path | Q | A | ------------- | --- | Branch? | 3.4 | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | symfony/recipes#253 (comment) | License | MIT | Doc PR | - Moving default `translations/` dir to the root project again. Commits ------- ba3476c Update default translations path
This PR was squashed before being merged into the master branch (closes #703). Discussion ---------- Moved translations back to the project root This was approved: symfony/recipes#253 so translations must be moved back to the project root dir. Commits ------- ec60dc2 Moved translations back to the project root
This PR was squashed before being merged into the master branch (closes #703). Discussion ---------- Moved translations back to the project root This was approved: symfony/recipes#253 so translations must be moved back to the project root dir. Commits ------- ec60dc2 Moved translations back to the project root
This PR was squashed before being merged into the master branch (closes #703). Discussion ---------- Moved translations back to the project root This was approved: symfony/recipes#253 so translations must be moved back to the project root dir. Commits ------- ec60dc2 Moved translations back to the project root
I propose to revert the changes done in #249. These are my reasons for doing so ... but of course there could be strong reasons too to not do it.
We've been using
translations/
for months ... and two days ago it was suddenly changed toconfig/translations/
. There wasn't a public discussion about it. Not even a single comment in #249. The proposal was made at 18:12 CET and merged at 18:50 CET. Just 38 minutes!!The full dir structure of a modern Symfony project is:
Removing
translations/
won't make it significantly more compact. However, hiding it insideconfig/
has a serious drawback: instead of being self-explanatory ("translations are stored in the translations/ dir. done!") you need to explain things: "translations are stored inside the config/ dir"Related to the previous point, it's very debatable to consider translations as part of the config. Some people do, others don't. In fact, the way translations are often used in Symfony, they are part of templates ... so they should be stored in
templates/translations/
instead ofconfig/
Historically, translations were never part of Symfony's config (
app/config/
) but of Symfony's resources (app/Resources/translations/
).Discoverability of this directory is important because it's one of those dirs that could be browsed by non backend developers (such as
assets/
andtemplates/
).