Is there a fast way to flush cache and empty static folders using putty commands? I am in developer mode and sometimes I dont know what I need to do so that the site updates my edits. Can one combine commands in putty and run at once?


1 Answer 1


Here is what you can do to run all commands in one go.

Combine all your commands in a single line joining them with && or ||

If you want to flush cache php bin/magento cache:flush and remove static folders rm -rf var/generation var/cache var/page_cache, You can join these two commands in a single line,

php bin/magento cache:flush && rm -rf var/generation var/cache var/page_cache

You can add as many of commands joining with && or ||

Reference1 Reference2


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.