8000 feature #6949 Update ProgressBar docs with regress information (james… · symfony/symfony-docs@cbe1aad · GitHub
[go: up one dir, main page]

Skip to content

Commit cbe1aad

Browse files
committed
feature #6949 Update ProgressBar docs with regress information (jameshalsall)
This PR was squashed before being merged into the master branch (closes #6949). Discussion ---------- Update ProgressBar docs with regress information Doc updates for changes introduced in symfony/symfony#19824 Commits ------- d3346d8 Update ProgressBar docs with regress information
2 parents 9a37e98 + d3346d8 commit cbe1aad

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

components/console/helpers/progressbar.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,12 @@ number of units, and advance the progress as the command executes::
3535
// ensure that the progress bar is at 100%
3636
$progress->finish();
3737

38+
.. tip::
39+
40+
You can also regress the progress bar (i.e. step backwards) by calling
41+
``$progress->advance()`` with a negative value. For example, if you call
42+
``$progress->advance(-2)`` then it will regress the progress bar 2 steps.
43+
3844
Instead of advancing the bar by a number of steps (with the
3945
:method:`Symfony\\Component\\Console\\Helper\\ProgressBar::advance` method),
4046
you can also set the current progress by calling the

0 commit comments

Comments
 (0)
0