Skip to main content

Drupal 8-9 Drush archive and dump database cli - terminal commands

With drupal 8-9 the drush ard command is dead. The King is dead long live drush sql:dump with zip or tar or whatever command you use for archiving - compressing your files. So for SQL dump archive - database backup file with compression drush sql:dump --gzip > db.gzip Official Documentation: https://drushcommands.com/drush-9x/sql/sql:dump/ For archiving the web root (project directory) zip -rXq d8project.28052020.zip d8project/. X: for Mac users hides all the unnecessary _MACOSX, ._Filename & .DS_Store files. q: (quite) compress files and directories without turning your terminal screen into a matrix screen.
drush