Skip to content

Commit 26493f3

Browse files
committed
Merge branch '2.8' into 3.4
* 2.8: Image to console Show console table examples in a console terminal Showed the output of the command in the same CLI window Replace entry/section by "article"
2 parents d264d83 + e88ffea commit 26493f3

27 files changed

+121
-64
lines changed

_images/components/console/table.png

-65.9 KB
Binary file not shown.
-46.6 KB
Binary file not shown.

_images/translation/debug_1.png

-22.2 KB
Binary file not shown.

_images/translation/debug_2.png

-22 KB
Binary file not shown.

_images/translation/debug_3.png

-21.9 KB
Binary file not shown.

_images/translation/debug_4.png

-21.7 KB
Binary file not shown.

components/console/helpers/table.rst

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Table
66

77
When building a console application it may be useful to display tabular data:
88

9-
.. code-block:: text
9+
.. code-block:: terminal
1010
1111
+---------------+--------------------------+------------------+
1212
| ISBN | Title | Author |
@@ -54,7 +54,7 @@ You can add a table separator anywhere in the output by passing an instance of
5454
array('80-902734-1-6', 'And Then There Were None', 'Agatha Christie'),
5555
));
5656

57-
.. code-block:: text
57+
.. code-block:: terminal
5858
5959
+---------------+--------------------------+------------------+
6060
| ISBN | Title | Author |
@@ -78,7 +78,7 @@ In this example, the first column width will be ``10``, the last column width
7878
will be ``30`` and the second column width will be calculated automatically
7979
because of the ``0`` value. The output of this command will be:
8080

81-
.. code-block:: text
81+
.. code-block:: terminal
8282
8383
+---------------+--------------------------+--------------------------------+
8484
| ISBN | Title | Author |
@@ -117,7 +117,7 @@ The table style can be changed to any built-in styles via
117117

118118
This code results in:
119119

120-
.. code-block:: text
120+
.. code-block:: terminal
121121
122122
ISBN Title Author
123123
99921-58-10-7 Divine Comedy Dante Alighieri
@@ -132,7 +132,7 @@ You can also set the style to ``borderless``::
132132

133133
which outputs:
134134

135-
.. code-block:: text
135+
.. code-block:: terminal
136136
137137
=============== ========================== ==================
138138
ISBN Title Author
@@ -205,7 +205,7 @@ To make a table cell that spans multiple columns you can use a :class:`Symfony\\
205205

206206
This results in:
207207

208-
.. code-block:: text
208+
.. code-block:: terminal
209209
210210
+---------------+---------------+-----------------+
211211
| ISBN | Title | Author |
@@ -228,7 +228,7 @@ This results in:
228228

229229
This generates:
230230

231-
.. code-block:: text
231+
.. code-block:: terminal
232232
233233
+-------+-------+--------+
234234
| Main table title |
@@ -259,7 +259,7 @@ In a similar way you can span multiple rows::
259259

260260
This outputs:
261261

262-
.. code-block:: text
262+
.. code-block:: terminal
263263
264264
+----------------+---------------+---------------------+
265265
| ISBN | Title | Author |

components/http_foundation/session_configuration.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
Configuring Sessions and Save Handlers
66
======================================
77

8-
This section deals with how to configure session management and fine tune it
8+
This article deals with how to configure session management and fine tune it
99
to your specific needs. This documentation covers save handlers, which
1010
store and retrieve session data, and configuring session behavior.
1111

components/phpunit_bridge.rst

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,23 @@ to provide more features:
7979
8080
After running your PHPUnit tests, you will get a report similar to this one:
8181

82-
.. image:: /_images/components/phpunit_bridge/report.png
82+
.. code-block:: terminal
83+
84+
$ phpunit -c app
85+
PHPUnit by Sebastian Bergmann.
86+
87+
Configuration read from <your-project>/app/phpunit.xml.dist
88+
.................
89+
90+
Time: 1.77 seconds, Memory: 5.75Mb
91+
92+
OK (17 tests, 21 assertions)
93+
94+
Remaining deprecation notices (2)
95+
96+
getEntityManager is deprecated since Symfony 2.1. Use getManager instead: 2x
97+
1x in DefaultControllerTest::testPublicUrls from AppBundle\Tests\Controller
98+
1x in BlogControllerTest::testIndex from AppBundle\Tests\Controller
8399
84100
The summary includes:
85101

components/security/firewall.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ certain action or resource of the application::
3636

3737
.. note::
3838

39-
Read the dedicated sections to learn more about :doc:`/components/security/authentication`
39+
Read the dedicated articles to learn more about :doc:`/components/security/authentication`
4040
and :doc:`/components/security/authorization`.
4141

4242
.. _firewall:
@@ -163,5 +163,5 @@ context works:
163163
#. Once a user is authenticated, you'll use :doc:`/components/security/authorization`
164164
to deny access to certain resources.
165165

166-
Read the next sections to find out more about :doc:`/components/security/authentication`
166+
Read the next articles to find out more about :doc:`/components/security/authentication`
167167
and :doc:`/components/security/authorization`.

deployment.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ setup:
202202
Application Lifecycle: Continuous Integration, QA, etc.
203203
-------------------------------------------------------
204204

205-
While this entry covers the technical details of deploying, the full lifecycle
205+
While this article covers the technical details of deploying, the full lifecycle
206206
of taking code from development up to production may have more steps:
207207
deploying to staging, QA (Quality Assurance), running tests, etc.
208208

doctrine/event_listeners_subscribers.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ to the tag like so:
237237
.. note::
238238

239239
  Marking an event listener as ``lazy`` has nothing to do with lazy service
240-
definitions which are described :doc:`in their own section </service_container/lazy_services>`
240+
definitions which are described :doc:`in their own article </service_container/lazy_services>`
241241

242242
.. _`The Event System`: http://docs.doctrine-project.org/projects/doctrine-orm/en/latest/reference/events.html
243243
.. _`the Doctrine Documentation`: http://docs.doctrine-project.org/projects/doctrine-orm/en/latest/reference/events.html#entity-listeners

doctrine/repository.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
How to Create custom Repository Classes
55
=======================================
66

7-
In the previous sections, you began constructing and using more complex queries
8-
from inside a controller. In order to isolate, reuse and test these queries,
9-
it's a good practice to create a custom repository class for your entity.
10-
Methods containing your query logic can then be stored in this class.
7+
Constructing and using complex queries inside controllers complicate the
8+
maintenance of your application. In order to isolate, reuse and test these
9+
queries, it's a good practice to create a custom repository class for your
10+
entity. Methods containing your query logic can then be stored in this class.
1111

1212
To do this, add the repository class name to your entity's mapping definition:
1313

form/dynamic_form_modification.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
How to Dynamically Modify Forms Using Form Events
55
=================================================
66

7-
Often times, a form can't be created statically. In this entry, you'll learn
7+
Often times, a form can't be created statically. In this article, you'll learn
88
how to customize your form based on three common use-cases:
99

1010
1) :ref:`form-events-underlying-data`
@@ -74,7 +74,7 @@ Suppose now, that you don't want the user to be able to change the ``name`` valu
7474
once the object has been created. To do this, you can rely on Symfony's
7575
:doc:`EventDispatcher component </components/event_dispatcher>`
7676
system to analyze the data on the object and modify the form based on the
77-
Product object's data. In this entry, you'll learn how to add this level of
77+
Product object's data. In this article, you'll learn how to add this level of
7878
flexibility to your forms.
7979

8080
Adding an Event Listener to a Form Class

form/form_collections.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@
44
How to Embed a Collection of Forms
55
==================================
66

7-
In this entry, you'll learn how to create a form that embeds a collection
7+
In this article, you'll learn how to create a form that embeds a collection
88
of many other forms. This could be useful, for example, if you had a ``Task``
99
class and you wanted to edit/create/remove many ``Tag`` objects related to
1010
that Task, right inside the same form.
1111

1212
.. note::
1313

14-
In this entry, it's loosely assumed that you're using Doctrine as your
14+
In this article, it's loosely assumed that you're using Doctrine as your
1515
database store. But if you're not using Doctrine (e.g. Propel or just
1616
a database connection), it's all very similar. There are only a few parts
1717
of this tutorial that really care about "persistence".
@@ -224,7 +224,7 @@ great, your user can't actually add any new tags yet.
224224

225225
.. caution::
226226

227-
In this entry, you embed only one collection, but you are not limited
227+
In this article, you embed only one collection, but you are not limited
228228
to this. You can also embed nested collection as many levels down as you
229229
like. But if you use Xdebug in your development setup, you may receive
230230
a ``Maximum function nesting level of '100' reached, aborting!`` error.

introduction/http_fundamentals.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ resource - the most common HTTP methods are:
7878
Delete the resource from the server (used by APIs).
7979

8080
With this in mind, you can imagine what an HTTP request might look like to
81-
delete a specific blog entry, for example:
81+
delete a specific blog post, for example:
8282

8383
.. code-block:: text
8484

routing.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ Routing Examples
2929

3030
A *route* is a map from a URL path to a controller. For example, suppose
3131
you want to match any URL like ``/blog/my-post`` or ``/blog/all-about-symfony``
32-
and send it to a controller that can look up and render that blog entry.
32+
and send it to a controller that can look up and render that blog post.
3333
The route is simple:
3434

3535
.. configuration-block::

security/acl.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ the ACL system comes in.
2121
:doc:`voters </security/voters>`. A voter is passed the object
2222
being voted on, which you can use to make complex decisions and effectively
2323
implement your own ACL. Enforcing authorization (e.g. the ``isGranted()``
24-
part) will look similar to what you see in this entry, but your voter
24+
part) will look similar to what you see in this article, but your voter
2525
class will handle the logic behind the scenes, instead of the ACL system.
2626

2727
Imagine you are designing a blog system where your users can comment on your

security/api_key_authentication.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@ to store authentication in the session, keep reading!
410410
Storing Authentication in the Session
411411
-------------------------------------
412412

413-
So far, this entry has described a situation where some sort of authentication
413+
So far, this article has described a situation where some sort of authentication
414414
token is sent on every request. But in some situations (like an OAuth flow),
415415
the token may be sent on only *one* request. In this case, you will want to
416416
authenticate the user and store that authentication in the session so that
@@ -569,7 +569,7 @@ of the user to make sure it's not out-of-date. But regardless of your requiremen
569569
Only Authenticating for Certain URLs
570570
------------------------------------
571571

572-
This entry has assumed that you want to look for the ``apikey`` authentication
572+
This article has assumed that you want to look for the ``apikey`` authentication
573573
on *every* request. But in some situations (like an OAuth flow), you only
574574
really need to look for authentication information once the user has reached
575575
a certain URL (e.g. the redirect URL in OAuth).

security/custom_authentication_provider.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ How to Create a custom Authentication Provider
66

77
.. tip::
88

9-
Creating a custom authentication system is hard, and this entry will walk
9+
Creating a custom authentication system is hard, and this article will walk
1010
you through that process. But depending on your needs, you may be able
1111
to solve your problem in a simpler manner, or via a community bundle:
1212

security/custom_password_authenticator.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ How to Create a Custom Form Password Authenticator
1010
flexible way to accomplish custom authentication tasks like this.
1111

1212
Imagine you want to allow access to your website only between 2pm and 4pm
13-
UTC. In this entry, you'll learn how to do this for a login form (i.e. where
13+
UTC. In this article, you'll learn how to do this for a login form (i.e. where
1414
your user submits their username and password).
1515

1616
The Password Authenticator

security/custom_provider.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ the configured user provider to return a user object for a given username.
1010
Symfony then checks whether the password of this user is correct and generates
1111
a security token so the user stays authenticated during the current session.
1212
Out of the box, Symfony has four user providers: ``memory``, ``entity``,
13-
``ldap`` and ``chain``. In this entry you'll see how you can create your
13+
``ldap`` and ``chain``. In this article you'll see how you can create your
1414
own user provider, which could be useful if your users are accessed via a
1515
custom database, a file, or - as shown in this example - a web service.
1616

@@ -294,7 +294,7 @@ is compared to the hashed password returned by your ``getPassword()`` method.
294294

295295
If your external users have their passwords salted via a different method,
296296
then you'll need to do a bit more work so that Symfony properly encodes
297-
the password. That is beyond the scope of this entry, but would include
297+
the password. That is beyond the scope of this article, but would include
298298
sub-classing ``MessageDigestPasswordEncoder`` and overriding the
299299
``mergePasswordAndSalt()`` method.
300300

security/entity_provider.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ and :ref:`user serialization to the session <security-serialize-equatable>`
3636
1) Create your User Entity
3737
--------------------------
3838

39-
For this entry, suppose that you already have a ``User`` entity inside an
39+
For this article, suppose that you already have a ``User`` entity inside an
4040
``AppBundle`` with the following fields: ``id``, ``username``, ``password``,
4141
``email`` and ``isActive``::
4242

service_container.rst

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -54,26 +54,25 @@ What other services are available? Find out by running:
5454

5555
.. code-block:: terminal
5656
57-
$ php bin/console debug:container
58-
59-
This is just a *small* sample of the output:
60-
61-
=============================== =======================================================================
62-
Service ID Class name
63-
=============================== =======================================================================
64-
doctrine ``Doctrine\Bundle\DoctrineBundle\Registry``
65-
filesystem ``Symfony\Component\Filesystem\Filesystem``
66-
form.factory ``Symfony\Component\Form\FormFactory``
67-
logger ``Symfony\Bridge\Monolog\Logger``
68-
request_stack ``Symfony\Component\HttpFoundation\RequestStack``
69-
router ``Symfony\Bundle\FrameworkBundle\Routing\Router``
70-
security.authorization_checker ``Symfony\Component\Security\Core\Authorization\AuthorizationChecker``
71-
security.password_encoder ``Symfony\Component\Security\Core\Encoder\UserPasswordEncoder``
72-
session ``Symfony\Component\HttpFoundation\Session\Session``
73-
translator ``Symfony\Component\Translation\DataCollectorTranslator``
74-
twig ``Twig\Environment``
75-
validator ``Symfony\Component\Validator\Validator\ValidatorInterface``
76-
=============================== =======================================================================
57+
$ php bin/console debug:container
58+
59+
# this is just a *small* sample of the output...
60+
=============================== =======================================================================
61+
Service ID Class name
62+
=============================== =======================================================================
63+
doctrine ``Doctrine\Bundle\DoctrineBundle\Registry``
64+
filesystem ``Symfony\Component\Filesystem\Filesystem``
65+
form.factory ``Symfony\Component\Form\FormFactory``
66+
logger ``Symfony\Bridge\Monolog\Logger``
67+
request_stack ``Symfony\Component\HttpFoundation\RequestStack``
68+
router ``Symfony\Bundle\FrameworkBundle\Routing\Router``
69+
security.authorization_checker ``Symfony\Component\Security\Core\Authorization\AuthorizationChecker``
70+
security.password_encoder ``Symfony\Component\Security\Core\Encoder\UserPasswordEncoder``
71+
session ``Symfony\Component\HttpFoundation\Session\Session``
72+
translator ``Symfony\Component\Translation\DataCollectorTranslator``
73+
twig ``Twig\Environment``
74+
validator ``Symfony\Component\Validator\Validator\ValidatorInterface``
75+
=============================== =======================================================================
7776
7877
You can also use the unique "Service ID" to access a service directly::
7978

setup/new_project_git.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ How to Create and Store a Symfony Project in Git
88

99
.. tip::
1010

11-
Though this entry is specifically about Git, the same generic principles
11+
Though this article is specifically about Git, the same generic principles
1212
will apply if you're storing your project in Subversion.
1313

1414
Once you've read through :doc:`/page_creation` and become familiar with

setup/new_project_svn.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ How to Create and Store a Symfony Project in Subversion
88

99
.. tip::
1010

11-
This entry is specifically about Subversion, and based on principles found
11+
This article is specifically about Subversion, and based on principles found
1212
in :doc:`/setup/new_project_git`.
1313

1414
Once you've read through :doc:`/page_creation` and become familiar with

0 commit comments

Comments
 (0)