diff --git a/.travis.yml b/.travis.yml index b75e460b6..8941e32e2 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,8 +28,8 @@ script: - ./bin/console lint:yaml app/config - ./bin/console lint:yaml @CodeExplorerBundle # this checks that the Twig template files contain no syntax errors - - ./bin/console lint:twig app/Resources @CodeExplorerBundle + - ./bin/console lint:twig templates @CodeExplorerBundle # this checks that the XLIFF translations contain no syntax errors - - ./bin/console lint:xliff app/Resources + - ./bin/console lint:xliff translations # this checks that the application doesn't use dependencies with known security vulnerabilities - ./bin/console security:check --end-point=http://security.sensiolabs.org/check_lock diff --git a/app/config/config.yml b/app/config/config.yml index a8a05527f..98c821f15 100644 --- a/app/config/config.yml +++ b/app/config/config.yml @@ -30,7 +30,7 @@ framework: # and with different cache configurations for each fragment # https://symfony.com/doc/current/book/http_cache.html#edge-side-includes esi: { enabled: true } - translator: { fallback: '%locale%' } + translator: { fallback: '%locale%', paths: ['%kernel.project_dir%/translations'] } secret: '%env(SYMFONY_SECRET)%' router: resource: '%kernel.project_dir%/app/config/routing.yml' @@ -64,6 +64,9 @@ twig: form_themes: - 'form/layout.html.twig' - 'form/fields.html.twig' + paths: + '%kernel.project_dir%/templates/TwigBundle': Twig + '%kernel.project_dir%/templates': ~ # Doctrine Configuration (used to access databases and manipulate their information) doctrine: diff --git a/app/Resources/TwigBundle/views/Exception/error.html.twig b/templates/TwigBundle/Exception/error.html.twig similarity index 100% rename from app/Resources/TwigBundle/views/Exception/error.html.twig rename to templates/TwigBundle/Exception/error.html.twig diff --git a/app/Resources/TwigBundle/views/Exception/error403.html.twig b/templates/TwigBundle/Exception/error403.html.twig similarity index 100% rename from app/Resources/TwigBundle/views/Exception/error403.html.twig rename to templates/TwigBundle/Exception/error403.html.twig diff --git a/app/Resources/TwigBundle/views/Exception/error404.html.twig b/templates/TwigBundle/Exception/error404.html.twig similarity index 100% rename from app/Resources/TwigBundle/views/Exception/error404.html.twig rename to templates/TwigBundle/Exception/error404.html.twig diff --git a/app/Resources/TwigBundle/views/Exception/error500.html.twig b/templates/TwigBundle/Exception/error500.html.twig similarity index 100% rename from app/Resources/TwigBundle/views/Exception/error500.html.twig rename to templates/TwigBundle/Exception/error500.html.twig diff --git a/app/Resources/views/admin/blog/_delete_form.html.twig b/templates/admin/blog/_delete_form.html.twig similarity index 100% rename from app/Resources/views/admin/blog/_delete_form.html.twig rename to templates/admin/blog/_delete_form.html.twig diff --git a/app/Resources/views/admin/blog/_form.html.twig b/templates/admin/blog/_form.html.twig similarity index 100% rename from app/Resources/views/admin/blog/_form.html.twig rename to templates/admin/blog/_form.html.twig diff --git a/app/Resources/views/admin/blog/edit.html.twig b/templates/admin/blog/edit.html.twig similarity index 100% rename from app/Resources/views/admin/blog/edit.html.twig rename to templates/admin/blog/edit.html.twig diff --git a/app/Resources/views/admin/blog/index.html.twig b/templates/admin/blog/index.html.twig similarity index 100% rename from app/Resources/views/admin/blog/index.html.twig rename to templates/admin/blog/index.html.twig diff --git a/app/Resources/views/admin/blog/new.html.twig b/templates/admin/blog/new.html.twig similarity index 100% rename from app/Resources/views/admin/blog/new.html.twig rename to templates/admin/blog/new.html.twig diff --git a/app/Resources/views/admin/blog/show.html.twig b/templates/admin/blog/show.html.twig similarity index 100% rename from app/Resources/views/admin/blog/show.html.twig rename to templates/admin/blog/show.html.twig diff --git a/app/Resources/views/admin/layout.html.twig b/templates/admin/layout.html.twig similarity index 100% rename from app/Resources/views/admin/layout.html.twig rename to templates/admin/layout.html.twig diff --git a/app/Resources/views/base.html.twig b/templates/base.html.twig similarity index 100% rename from app/Resources/views/base.html.twig rename to templates/base.html.twig diff --git a/app/Resources/views/blog/_comment_form.html.twig b/templates/blog/_comment_form.html.twig similarity index 100% rename from app/Resources/views/blog/_comment_form.html.twig rename to templates/blog/_comment_form.html.twig diff --git a/app/Resources/views/blog/_delete_post_confirmation.html.twig b/templates/blog/_delete_post_confirmation.html.twig similarity index 100% rename from app/Resources/views/blog/_delete_post_confirmation.html.twig rename to templates/blog/_delete_post_confirmation.html.twig diff --git a/app/Resources/views/blog/_post_tags.html.twig b/templates/blog/_post_tags.html.twig similarity index 100% rename from app/Resources/views/blog/_post_tags.html.twig rename to templates/blog/_post_tags.html.twig diff --git a/app/Resources/views/blog/_rss.html.twig b/templates/blog/_rss.html.twig similarity index 100% rename from app/Resources/views/blog/_rss.html.twig rename to templates/blog/_rss.html.twig diff --git a/app/Resources/views/blog/about.html.twig b/templates/blog/about.html.twig similarity index 100% rename from app/Resources/views/blog/about.html.twig rename to templates/blog/about.html.twig diff --git a/app/Resources/views/blog/comment_form_error.html.twig b/templates/blog/comment_form_error.html.twig similarity index 100% rename from app/Resources/views/blog/comment_form_error.html.twig rename to templates/blog/comment_form_error.html.twig diff --git a/app/Resources/views/blog/index.html.twig b/templates/blog/index.html.twig similarity index 100% rename from app/Resources/views/blog/index.html.twig rename to templates/blog/index.html.twig diff --git a/app/Resources/views/blog/index.xml.twig b/templates/blog/index.xml.twig similarity index 100% rename from app/Resources/views/blog/index.xml.twig rename to templates/blog/index.xml.twig diff --git a/app/Resources/views/blog/post_show.html.twig b/templates/blog/post_show.html.twig similarity index 100% rename from app/Resources/views/blog/post_show.html.twig rename to templates/blog/post_show.html.twig diff --git a/app/Resources/views/default/_flash_messages.html.twig b/templates/default/_flash_messages.html.twig similarity index 100% rename from app/Resources/views/default/_flash_messages.html.twig rename to templates/default/_flash_messages.html.twig diff --git a/app/Resources/views/default/homepage.html.twig b/templates/default/homepage.html.twig similarity index 100% rename from app/Resources/views/default/homepage.html.twig rename to templates/default/homepage.html.twig diff --git a/app/Resources/views/form/fields.html.twig b/templates/form/fields.html.twig similarity index 100% rename from app/Resources/views/form/fields.html.twig rename to templates/form/fields.html.twig diff --git a/app/Resources/views/form/layout.html.twig b/templates/form/layout.html.twig similarity index 100% rename from app/Resources/views/form/layout.html.twig rename to templates/form/layout.html.twig diff --git a/app/Resources/views/security/login.html.twig b/templates/security/login.html.twig similarity index 100% rename from app/Resources/views/security/login.html.twig rename to templates/security/login.html.twig diff --git a/app/Resources/translations/messages.ca.xlf b/translations/messages.ca.xlf similarity index 100% rename from app/Resources/translations/messages.ca.xlf rename to translations/messages.ca.xlf diff --git a/app/Resources/translations/messages.cs.xlf b/translations/messages.cs.xlf similarity index 100% rename from app/Resources/translations/messages.cs.xlf rename to translations/messages.cs.xlf diff --git a/app/Resources/translations/messages.de.xlf b/translations/messages.de.xlf similarity index 100% rename from app/Resources/translations/messages.de.xlf rename to translations/messages.de.xlf diff --git a/app/Resources/translations/messages.en.xlf b/translations/messages.en.xlf similarity index 100% rename from app/Resources/translations/messages.en.xlf rename to translations/messages.en.xlf diff --git a/app/Resources/translations/messages.es.xlf b/translations/messages.es.xlf similarity index 100% rename from app/Resources/translations/messages.es.xlf rename to translations/messages.es.xlf diff --git a/app/Resources/translations/messages.fr.xlf b/translations/messages.fr.xlf similarity index 100% rename from app/Resources/translations/messages.fr.xlf rename to translations/messages.fr.xlf diff --git a/app/Resources/translations/messages.hr.xlf b/translations/messages.hr.xlf similarity index 100% rename from app/Resources/translations/messages.hr.xlf rename to translations/messages.hr.xlf diff --git a/app/Resources/translations/messages.id.xlf b/translations/messages.id.xlf similarity index 100% rename from app/Resources/translations/messages.id.xlf rename to translations/messages.id.xlf diff --git a/app/Resources/translations/messages.it.xlf b/translations/messages.it.xlf similarity index 100% rename from app/Resources/translations/messages.it.xlf rename to translations/messages.it.xlf diff --git a/app/Resources/translations/messages.ja.xlf b/translations/messages.ja.xlf similarity index 100% rename from app/Resources/translations/messages.ja.xlf rename to translations/messages.ja.xlf diff --git a/app/Resources/translations/messages.nl.xlf b/translations/messages.nl.xlf similarity index 100% rename from app/Resources/translations/messages.nl.xlf rename to translations/messages.nl.xlf diff --git a/app/Resources/translations/messages.pl.xlf b/translations/messages.pl.xlf similarity index 100% rename from app/Resources/translations/messages.pl.xlf rename to translations/messages.pl.xlf diff --git a/app/Resources/translations/messages.pt_BR.xlf b/translations/messages.pt_BR.xlf similarity index 100% rename from app/Resources/translations/messages.pt_BR.xlf rename to translations/messages.pt_BR.xlf diff --git a/app/Resources/translations/messages.ro.xlf b/translations/messages.ro.xlf similarity index 100% rename from app/Resources/translations/messages.ro.xlf rename to translations/messages.ro.xlf diff --git a/app/Resources/translations/messages.ru.xlf b/translations/messages.ru.xlf similarity index 100% rename from app/Resources/translations/messages.ru.xlf rename to translations/messages.ru.xlf diff --git a/app/Resources/translations/messages.sl.xlf b/translations/messages.sl.xlf similarity index 100% rename from app/Resources/translations/messages.sl.xlf rename to translations/messages.sl.xlf diff --git a/app/Resources/translations/messages.uk.xlf b/translations/messages.uk.xlf similarity index 100% rename from app/Resources/translations/messages.uk.xlf rename to translations/messages.uk.xlf diff --git a/app/Resources/translations/messages.zh_CN.xlf b/translations/messages.zh_CN.xlf similarity index 100% rename from app/Resources/translations/messages.zh_CN.xlf rename to translations/messages.zh_CN.xlf diff --git a/app/Resources/translations/validators.ca.xlf b/translations/validators.ca.xlf similarity index 100% rename from app/Resources/translations/validators.ca.xlf rename to translations/validators.ca.xlf diff --git a/app/Resources/translations/validators.cs.xlf b/translations/validators.cs.xlf similarity index 100% rename from app/Resources/translations/validators.cs.xlf rename to translations/validators.cs.xlf diff --git a/app/Resources/translations/validators.de.xlf b/translations/validators.de.xlf similarity index 100% rename from app/Resources/translations/validators.de.xlf rename to translations/validators.de.xlf diff --git a/app/Resources/translations/validators.en.xlf b/translations/validators.en.xlf similarity index 100% rename from app/Resources/translations/validators.en.xlf rename to translations/validators.en.xlf diff --git a/app/Resources/translations/validators.es.xlf b/translations/validators.es.xlf similarity index 100% rename from app/Resources/translations/validators.es.xlf rename to translations/validators.es.xlf diff --git a/app/Resources/translations/validators.fr.xlf b/translations/validators.fr.xlf similarity index 100% rename from app/Resources/translations/validators.fr.xlf rename to translations/validators.fr.xlf diff --git a/app/Resources/translations/validators.hr.xlf b/translations/validators.hr.xlf similarity index 100% rename from app/Resources/translations/validators.hr.xlf rename to translations/validators.hr.xlf diff --git a/app/Resources/translations/validators.id.xlf b/translations/validators.id.xlf similarity index 100% rename from app/Resources/translations/validators.id.xlf rename to translations/validators.id.xlf diff --git a/app/Resources/translations/validators.it.xlf b/translations/validators.it.xlf similarity index 100% rename from app/Resources/translations/validators.it.xlf rename to translations/validators.it.xlf diff --git a/app/Resources/translations/validators.ja.xlf b/translations/validators.ja.xlf similarity index 100% rename from app/Resources/translations/validators.ja.xlf rename to translations/validators.ja.xlf diff --git a/app/Resources/translations/validators.nl.xlf b/translations/validators.nl.xlf similarity index 100% rename from app/Resources/translations/validators.nl.xlf rename to translations/validators.nl.xlf diff --git a/app/Resources/translations/validators.pl.xlf b/translations/validators.pl.xlf similarity index 100% rename from app/Resources/translations/validators.pl.xlf rename to translations/validators.pl.xlf diff --git a/app/Resources/translations/validators.pt_BR.xlf b/translations/validators.pt_BR.xlf similarity index 100% rename from app/Resources/translations/validators.pt_BR.xlf rename to translations/validators.pt_BR.xlf diff --git a/app/Resources/translations/validators.ro.xlf b/translations/validators.ro.xlf similarity index 100% rename from app/Resources/translations/validators.ro.xlf rename to translations/validators.ro.xlf diff --git a/app/Resources/translations/validators.ru.xlf b/translations/validators.ru.xlf similarity index 100% rename from app/Resources/translations/validators.ru.xlf rename to translations/validators.ru.xlf diff --git a/app/Resources/translations/validators.sl.xlf b/translations/validators.sl.xlf similarity index 100% rename from app/Resources/translations/validators.sl.xlf rename to translations/validators.sl.xlf diff --git a/app/Resources/translations/validators.uk.xlf b/translations/validators.uk.xlf similarity index 100% rename from app/Resources/translations/validators.uk.xlf rename to translations/validators.uk.xlf diff --git a/app/Resources/translations/validators.zh_CN.xlf b/translations/validators.zh_CN.xlf similarity index 100% rename from app/Resources/translations/validators.zh_CN.xlf rename to translations/validators.zh_CN.xlf