Skip to content

Commit c45a7f2

Browse files
committed
Merge branch '3.2'
* 3.2: (22 commits) Rename "console tasks" to "console commands" [Workflow] Add tip for workflow configuration default values Reflect private to hidden renaming in the file name Reflect renaming from private to hidden Added an article about private console commands Updated the explanation about framework.ide [symfony#7214] fix option's default value strict default option for choice validation Reworded the user checker aliases explanation Remove duplicate use operator [Fix][httpKernel] Wrong links [Fix][Console] Missing autoloading by Composer Revert "Fixed wrong inheritance information" [symfony#7318] Removing unnecessary word Minor fixes Explain what is the Symfony Core team Added the references to security vulnerabilities discovered in 2016 Improve configuration example text indents update year in license template describe should have an 's' on the end ...
2 parents e41f358 + 2ad5fb9 commit c45a7f2

File tree

23 files changed

+116
-65
lines changed

23 files changed

+116
-65
lines changed

components/console/usage.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ built-in options as well as a couple of built-in commands for the Console compon
1616
<?php
1717
// application.php
1818

19+
require __DIR__.'/vendor/autoload.php';
20+
1921
use Symfony\Component\Console\Application;
2022

2123
$application = new Application();

components/form.rst

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -194,20 +194,25 @@ to bootstrap or access Twig and add the :class:`Symfony\\Bridge\\Twig\\Extension
194194
$vendorTwigBridgeDir.'/Resources/views/Form',
195195
)));
196196
$formEngine = new TwigRendererEngine(array($defaultFormTheme));
197-
$formEngine->setEnvironment($twig);
197+
$twig->addRuntimeLoader(new \Twig_FactoryRuntimeLoader(array(
198+
TwigRenderer::class => function () use ($formEngine, $csrfManager) {
199+
return new TwigRenderer($formEngine, $csrfManager);
200+
},
201+
)));
198202

199203
// ... (see the previous CSRF Protection section for more information)
200204

201205
// add the FormExtension to Twig
202-
$twig->addExtension(
203-
new FormExtension(new TwigRenderer($formEngine, $csrfManager))
204-
);
206+
$twig->addExtension(new FormExtension());
205207

206208
// create your form factory as normal
207209
$formFactory = Forms::createFormFactoryBuilder()
208210
// ...
209211
->getFormFactory();
210212

213+
.. versionadded:: 1.30
214+
The ``Twig_FactoryRuntimeLoader`` was introduced in Twig 1.30.
215+
211216
The exact details of your `Twig Configuration`_ will vary, but the goal is
212217
always to add the :class:`Symfony\\Bridge\\Twig\\Extension\\FormExtension`
213218
to Twig, which gives you access to the Twig functions for rendering forms.

components/http_kernel.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,9 @@ For general information on adding listeners to the events below, see
124124

125125
.. caution::
126126

127-
As of 3.1 the :class:`Symfony\\Component\\Httpkernel\\HttpKernel` accepts a
127+
As of 3.1 the :class:`Symfony\\Component\\HttpKernel\\HttpKernel` accepts a
128128
fourth argument, which must be an instance of
129-
:class:`Symfony\\Component\\Httpkernel\\Controller\\ArgumentResolverInterface`.
129+
:class:`Symfony\\Component\\HttpKernel\\Controller\\ArgumentResolverInterface`.
130130
In 4.0 this argument will become mandatory.
131131

132132
.. seealso::

console/hide_commands.rst

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
How to Hide Console Commands
2+
============================
3+
4+
By default, all console commands are listed when executing the console application
5+
script without arguments or when using the ``list`` command.
6+
7+
However, sometimes commands are not intended to be executed by end-users; for
8+
example, commands for the legacy parts of the application, commands exclusively
9+
executed through scheduled tasks, etc.
10+
11+
In those cases, you can define the command as **hidden** by setting the
12+
``setHidden()`` method to ``true`` in the command configuration::
13+
14+
// src/AppBundle/Command/LegacyCommand.php
15+
namespace AppBundle\Command;
16+
17+
use Symfony\Component\Console\Command\Command;
18+
19+
class LegacyCommand extends Command
20+
{
21+
protected function configure()
22+
{
23+
$this
24+
->setName('app:legacy')
25+
->setHidden(true)
26+
// ...
27+
;
28+
}
29+
}
30+
31+
Hidden commands behave the same as normal commands but they are no longer displayed
32+
in command listings, so end-users are not aware of their existence.

console/input.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ Next, use this in the command to print the message multiple times::
134134
$output->writeln($text);
135135
}
136136

137-
Now, when you run the task, you can optionally specify a ``--iterations``
137+
Now, when you run the command, you can optionally specify a ``--iterations``
138138
flag:
139139

140140
.. code-block:: terminal

contributing/code/core_team.rst

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,15 @@
11
Symfony Core Team
22
=================
33

4-
This document states the rules that govern the Symfony Core group. These rules
4+
The **Symfony Core** team is the group of developers that determine the
5+
direction and evolution of the Symfony project. Their votes rule if the
6+
features and patches proposed by the community are approved or rejected.
7+
8+
All the Symfony Core members are long-time contributors with solid technical
9+
expertise and they have demonstrated a strong commitment to drive the project
10+
forward.
11+
12+
This document states the rules that govern the Symfony Core team. These rules
513
are effective upon publication of this document and all Symfony Core members
614
must adhere to said rules and protocol.
715

contributing/code/license.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ According to `Wikipedia`_:
1616
The License
1717
-----------
1818

19-
Copyright (c) 2004-2016 Fabien Potencier
19+
Copyright (c) 2004-2017 Fabien Potencier
2020

2121
Permission is hereby granted, free of charge, to any person obtaining a copy
2222
of this software and associated documentation files (the "Software"), to deal

contributing/code/security.rst

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,11 @@ Security Advisories
103103
This section indexes security vulnerabilities that were fixed in Symfony
104104
releases, starting from Symfony 1.0.0:
105105

106-
* November 23, 2015: `CVE-2015-8125: Potential Remote Timing Attack Vulnerability in Security Remember-Me Service <http://symfony.com/blog/cve-2015-8125-potential-remote-timing-attack-vulnerability-in-security-remember-me-service>`_ (2.3.35, 2.6.12 and 2.7.7)
107-
* November 23, 2015: `CVE-2015-8124: Session Fixation in the "Remember Me" Login Feature <http://symfony.com/blog/cve-2015-8124-session-fixation-in-the-remember-me-login-feature>`_ (2.3.35, 2.6.12 and 2.7.7)
106+
* May 9, 2016: `CVE-2016-2403: Unauthorized access on a misconfigured Ldap server when using an empty password <http://symfony.com/blog/cve-2016-2403-unauthorized-access-on-a-misconfigured-ldap-server-when-using-an-empty-password>`_ (2.8.0-2.8.5, 3.0.0-3.0.5)
107+
* May 9, 2016: `CVE-2016-4423: Large username storage in session <https://symfony.com/blog/cve-2016-4423-large-username-storage-in-session>`_ (2.3.0-2.3.40, 2.7.0-2.7.12, 2.8.0-2.8.5, 3.0.0-3.0.5)
108+
* January 18, 2016: `CVE-2016-1902: SecureRandom's fallback not secure when OpenSSL fails <https://symfony.com/blog/cve-2016-1902-securerandom-s-fallback-not-secure-when-openssl-fails>`_ (2.3.0-2.3.36, 2.6.0-2.6.12, 2.7.0-2.7.8)
109+
* November 23, 2015: `CVE-2015-8125: Potential Remote Timing Attack Vulnerability in Security Remember-Me Service <https://symfony.com/blog/cve-2015-8125-potential-remote-timing-attack-vulnerability-in-security-remember-me-service>`_ (2.3.35, 2.6.12 and 2.7.7)
110+
* November 23, 2015: `CVE-2015-8124: Session Fixation in the "Remember Me" Login Feature <https://symfony.com/blog/cve-2015-8124-session-fixation-in-the-remember-me-login-feature>`_ (2.3.35, 2.6.12 and 2.7.7)
108111
* May 26, 2015: `CVE-2015-4050: ESI unauthorized access <https://symfony.com/blog/cve-2015-4050-esi-unauthorized-access>`_ (Symfony 2.3.29, 2.5.12 and 2.6.8)
109112
* April 1, 2015: `CVE-2015-2309: Unsafe methods in the Request class <https://symfony.com/blog/cve-2015-2309-unsafe-methods-in-the-request-class>`_ (Symfony 2.3.27, 2.5.11 and 2.6.6)
110113
* April 1, 2015: `CVE-2015-2308: Esi Code Injection <https://symfony.com/blog/cve-2015-2308-esi-code-injection>`_ (Symfony 2.3.27, 2.5.11 and 2.6.6)

create_framework/routing.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ Instead of an array for the URL map, the Routing component relies on a
5656

5757
$routes = new RouteCollection();
5858

59-
Let's add a route that describe the ``/hello/SOMETHING`` URL and add another
59+
Let's add a route that describes the ``/hello/SOMETHING`` URL and add another
6060
one for the simple ``/bye`` one::
6161

6262
use Symfony\Component\Routing\Route;

doctrine.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -518,7 +518,7 @@ in your application. To do this, run:
518518
your entities) with how it *actually* looks, and executes the SQL statements
519519
needed to *update* the database schema to where it should be. In other
520520
words, if you add a new property with mapping metadata to ``Product``
521-
and run this task, it will execute the "ALTER TABLE" statement needed
521+
and run this command, it will execute the "ALTER TABLE" statement needed
522522
to add that new column to the existing ``product`` table.
523523

524524
An even better way to take advantage of this functionality is via

0 commit comments

Comments
 (0)