Thursday, 1 February 2018

Symfony console command basics

Let's take a look on symfony command.It very easy in symfony to check the existing command and list of all commands. Execute the following to check all the existing feature commands in console.

symfony console commands basics

run this command in your root directory,

php bin/console

You will see a list of existing commands. Each supported command has a short details. Each of the standard commands come with help, so I will not be describing each of them here, but it is worth to mention a few commonly used ones:

php bin/console: cache:clear

Symfonys in production store more data in caching. Therefore, if you need to change values within a template (Twig) or within configuration files while in production mode, you will need to clear the cache. Cache is also one of the reasons why it’s worth to work in the development mode.

php bin/console container:debug

Displays all configured public services in symfony.

php bin/console router:debug

It will displays all routing configuration along with method, scheme, host, and path.

php bin/console security:check

Checks your composer and packages version against known security vulnerabilities. You should run this command regularly.

Featured post

How to create dynamic schema in mongodb

Sometime what we need in our application is to create mongodb schema for collection and some of our collection schema are same but names are...

Popular Posts