SlideShare una empresa de Scribd logo
1 de 17
Descargar para leer sin conexión
Drush to
simplify
Drupalers work
Sivaji J.G,
KnackForge Soft Solutions Pvt. Ltd.
About Speaker

•
•
•
•
•
•
•
•

Started Drupal evangelism as trainee in 2008
Integrated Drupal and gnokii for accessing bus routes
information via SMS
GSoC Alumnus 2009
Co-maintainer of quiz module
Contributor to Drupal Core and Contrib modules in drupal.org
Technical reviewer of Drupal books
Featured Speaker / Trainer of Drupal Chennai workshops
Technical Director / Drupal project manager at KnackForge
Agenda

•
•
•
•

What is Drush?
Requirements and Installation
How it works?
Drush commands
What is Drush?

•
•

•
•
•

•

Command line utility to administer Drupal sites
Typically used as “drush [options] <command>
[argument1] [argument2]”
Commonly used for cache clear, managing modules /
themes / features, cron, etc.
Supports Drupal 6.x and above
Works best on Unix like OS and partially supported
for Windows
Maintained in GitHub /drush-ops/drush
Requirements and Installation

•
•

From PEAR
o

https://github.com/drush-ops/drush#install---pear

Manual Installation
o

https://github.com/drush-ops/drush#install---manual
How it works
Drush Commands

•
•
•
•
•
•
•
•
•

pm-download
site-install
user-password
variable-get / set
cache-clear
core-cron
core-status
php-script
updatedb

•
•
•
•
•
•
•
•
•

watchdog-show
pm-list
pm-enable
pm-disable
pm-uninstall
sql-drop
sql-query
sql-sync
sql-connect
$ drush pm-download (dl)

•
•

•
•
•
•

Download any projects from drupal.org
Project could Drupal core, modules, themes or
profiles.
Handles project dependency
Sticks to recommended versions by default
Automatically figure out which project version you
want based
Integrates with version control system (git, svn
$ drush pm-download (dl)
Usage
$ drush dl
Project drupal (7.23) downloaded to
/home/sivaji/Public/drupal-7.23. [success]
Project drupal contains: [success]
- 3 profiles: standard, testing, minimal
- 4 themes: bartik, garland, stark, seven
- 47 modules: image, openid, simpletest,...
$ drush pm-download (dl)
$ drush dl views
Project views (7.x-3.7) downloaded to
/home/sivaji/Public/drupal-7.23/sites/all/modules/views.
[success]

$ drush dl zen
$ drush dl features-7.x-2.x-dev
$ drush site-install (si)
Installs Drupal with specified install profile
Usage
$ drush si standard --site-name="Drush
Test"
--db-url=<mysql://root:pass@127.0.0.1/db
More default values

•
•
•

o

--account-mail, --account-name, --db-prefix, --locale,
--site-mail, [form name].[parameter name]
$ drush site-install (si)
$ drush si standard --site-name="Drupal Camp" --dburl=mysql://root@127.0.0.1/learning_drush
You are about to create a sites/default/files directory and create a
sites/default/settings.php file and CREATE the 'learning_drush' database.
Do you want to continue? (y/n): y
Starting Drupal installation. This takes a few seconds ...
[ok]
Installation complete. User name: admin User password: AGn744iDVd
$ drush user-password (upwd)
(Re)Set the password for the user account with the
specified name
Usage:
Changing the auto generated password AGn744iDVd to
Admin!@# for admin user.
$ drush upwd admin --password=Admin!@#
$ drush variable-get / variable-set
(vget/vset)
Get a list of some or all site variables and
values.
Usage
$ drush variable-get site_name
site_name: "Drupal Camp"
$ drush variable-set site_name "Drupal Camp
Delhi"
$ drush cache-clear (cc)
Clear a specific cache, or all drupal caches
Usage,
$ drush cc all
$ drush cc menu
$ drush cache-clear (cc)
$ drush cc
Enter a number to choose which cache to clear.
[0] : Cancel
[1] : all
[2] : drush
[3] : theme-registry
[4] : menu

[5] : css-js
[6] : block
[7] : module-list
[8] : theme-list

[9] : registry
[10] : token
[11] : views
More slides to come

Más contenido relacionado

La actualidad más candente

Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
camp_drupal_ua
 
Ts drupal6 module development v0.2
Ts   drupal6 module development v0.2Ts   drupal6 module development v0.2
Ts drupal6 module development v0.2
Confiz
 

La actualidad más candente (13)

Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
Anna Fedoruk.Theworkflow.DrupalCamp Kyiv 2011
 
Dc kyiv2010 jun_08
Dc kyiv2010 jun_08Dc kyiv2010 jun_08
Dc kyiv2010 jun_08
 
大規模サイトにおけるユーザーレベルのキャッシュ活用によるパフォーマンスチューニング
大規模サイトにおけるユーザーレベルのキャッシュ活用によるパフォーマンスチューニング大規模サイトにおけるユーザーレベルのキャッシュ活用によるパフォーマンスチューニング
大規模サイトにおけるユーザーレベルのキャッシュ活用によるパフォーマンスチューニング
 
Drush workshop
Drush workshopDrush workshop
Drush workshop
 
SynapseIndia drupal presentation on drupal
SynapseIndia drupal  presentation on drupalSynapseIndia drupal  presentation on drupal
SynapseIndia drupal presentation on drupal
 
Drupal 8 Theme System: The Backend of Frontend
Drupal 8 Theme System: The Backend of FrontendDrupal 8 Theme System: The Backend of Frontend
Drupal 8 Theme System: The Backend of Frontend
 
Drupal on your laptop
Drupal on your laptopDrupal on your laptop
Drupal on your laptop
 
Common Pitfalls for your Drupal Site, and How to Avoid Them
Common Pitfalls for your Drupal Site, and How to Avoid ThemCommon Pitfalls for your Drupal Site, and How to Avoid Them
Common Pitfalls for your Drupal Site, and How to Avoid Them
 
Fast Paced Drupal 8: Accelerating Development with Composer, Drupal Console a...
Fast Paced Drupal 8: Accelerating Development with Composer, Drupal Console a...Fast Paced Drupal 8: Accelerating Development with Composer, Drupal Console a...
Fast Paced Drupal 8: Accelerating Development with Composer, Drupal Console a...
 
Ts drupal6 module development v0.2
Ts   drupal6 module development v0.2Ts   drupal6 module development v0.2
Ts drupal6 module development v0.2
 
Drupal 8
Drupal 8Drupal 8
Drupal 8
 
Drupal 8
Drupal 8Drupal 8
Drupal 8
 
2011 - DDU - Intro to Drush
2011 - DDU - Intro to Drush2011 - DDU - Intro to Drush
2011 - DDU - Intro to Drush
 

Similar a Drush to simplify Drupalers work - Sivaji

Drush and drupal. администрирование. Волчек Михаил
Drush and drupal. администрирование. Волчек МихаилDrush and drupal. администрирование. Волчек Михаил
Drush and drupal. администрирование. Волчек Михаил
PVasili
 
Drush and drupal. администрирование волчек михаил
Drush and drupal. администрирование  волчек михаилDrush and drupal. администрирование  волчек михаил
Drush and drupal. администрирование волчек михаил
drupalconf
 
Drush&drupal. administration
Drush&drupal. administrationDrush&drupal. administration
Drush&drupal. administration
zabej
 
Speed up Drupal development with Drush
Speed up Drupal development with DrushSpeed up Drupal development with Drush
Speed up Drupal development with Drush
kbasarab
 
Depolying Drupal with Git, Drush Make and Capistrano
Depolying Drupal with Git, Drush Make and CapistranoDepolying Drupal with Git, Drush Make and Capistrano
Depolying Drupal with Git, Drush Make and Capistrano
libsys
 
Doing Drupal security right from Drupalcon London
Doing Drupal security right from Drupalcon LondonDoing Drupal security right from Drupalcon London
Doing Drupal security right from Drupalcon London
Gábor Hojtsy
 

Similar a Drush to simplify Drupalers work - Sivaji (20)

Drush and drupal. администрирование. Волчек Михаил
Drush and drupal. администрирование. Волчек МихаилDrush and drupal. администрирование. Волчек Михаил
Drush and drupal. администрирование. Волчек Михаил
 
Drush and drupal. администрирование волчек михаил
Drush and drupal. администрирование  волчек михаилDrush and drupal. администрирование  волчек михаил
Drush and drupal. администрирование волчек михаил
 
Intro to Drush
Intro to DrushIntro to Drush
Intro to Drush
 
Drush&drupal. administration
Drush&drupal. administrationDrush&drupal. administration
Drush&drupal. administration
 
A Drush Primer - DrupalCamp Chattanooga 2013
A Drush Primer - DrupalCamp Chattanooga 2013A Drush Primer - DrupalCamp Chattanooga 2013
A Drush Primer - DrupalCamp Chattanooga 2013
 
Drush for drupal website builder
Drush for drupal website builderDrush for drupal website builder
Drush for drupal website builder
 
Drush
DrushDrush
Drush
 
Beginning Drush
Beginning DrushBeginning Drush
Beginning Drush
 
Speed up Drupal development with Drush
Speed up Drupal development with DrushSpeed up Drupal development with Drush
Speed up Drupal development with Drush
 
Improving your Drupal 8 development workflow DrupalCampLA
Improving your Drupal 8 development workflow DrupalCampLAImproving your Drupal 8 development workflow DrupalCampLA
Improving your Drupal 8 development workflow DrupalCampLA
 
Intro to Drush
Intro to DrushIntro to Drush
Intro to Drush
 
Welcome aboard the team
Welcome aboard the teamWelcome aboard the team
Welcome aboard the team
 
Boost your theming skills - Artem Shymko
Boost your theming skills - Artem ShymkoBoost your theming skills - Artem Shymko
Boost your theming skills - Artem Shymko
 
Boost your theming skills
Boost your theming skillsBoost your theming skills
Boost your theming skills
 
Building a Drupal Distribution using Features, Drush Make, Installation Profi...
Building a Drupal Distribution using Features, Drush Make, Installation Profi...Building a Drupal Distribution using Features, Drush Make, Installation Profi...
Building a Drupal Distribution using Features, Drush Make, Installation Profi...
 
Lightning Fast Drupal Theming (Drupal 7)
Lightning Fast Drupal Theming (Drupal 7)Lightning Fast Drupal Theming (Drupal 7)
Lightning Fast Drupal Theming (Drupal 7)
 
drush_multi @ DrupalDevDays 2010
drush_multi @ DrupalDevDays 2010drush_multi @ DrupalDevDays 2010
drush_multi @ DrupalDevDays 2010
 
Face your fears: Drush and Aegir
Face your fears: Drush and AegirFace your fears: Drush and Aegir
Face your fears: Drush and Aegir
 
Depolying Drupal with Git, Drush Make and Capistrano
Depolying Drupal with Git, Drush Make and CapistranoDepolying Drupal with Git, Drush Make and Capistrano
Depolying Drupal with Git, Drush Make and Capistrano
 
Doing Drupal security right from Drupalcon London
Doing Drupal security right from Drupalcon LondonDoing Drupal security right from Drupalcon London
Doing Drupal security right from Drupalcon London
 

Más de Drupal Camp Delhi

Campusdiaries Showcase - Raj Chourasia
Campusdiaries Showcase - Raj ChourasiaCampusdiaries Showcase - Raj Chourasia
Campusdiaries Showcase - Raj Chourasia
Drupal Camp Delhi
 
Generics & Specifics of QA on Web - Sweta Shahi
Generics & Specifics of QA on Web - Sweta ShahiGenerics & Specifics of QA on Web - Sweta Shahi
Generics & Specifics of QA on Web - Sweta Shahi
Drupal Camp Delhi
 
Memcache and Drupal - Vaibhav Jain
Memcache and Drupal - Vaibhav JainMemcache and Drupal - Vaibhav Jain
Memcache and Drupal - Vaibhav Jain
Drupal Camp Delhi
 
How NOT to build Drupal Sites - Sai Tanay
How NOT to build Drupal Sites - Sai TanayHow NOT to build Drupal Sites - Sai Tanay
How NOT to build Drupal Sites - Sai Tanay
Drupal Camp Delhi
 
Amplify user engagement with Game Mechanics - Vidhatanand
Amplify user engagement with Game Mechanics - VidhatanandAmplify user engagement with Game Mechanics - Vidhatanand
Amplify user engagement with Game Mechanics - Vidhatanand
Drupal Camp Delhi
 
Future proof your drupal skills - Piyuesh Kumar
Future proof your drupal skills - Piyuesh KumarFuture proof your drupal skills - Piyuesh Kumar
Future proof your drupal skills - Piyuesh Kumar
Drupal Camp Delhi
 
Basic Responsive Theming - Somedutta Ghosh
Basic Responsive Theming - Somedutta GhoshBasic Responsive Theming - Somedutta Ghosh
Basic Responsive Theming - Somedutta Ghosh
Drupal Camp Delhi
 
What is there in Drupal Community & their do's and don't's - Sivaji
What is there in Drupal Community & their do's and don't's - SivajiWhat is there in Drupal Community & their do's and don't's - Sivaji
What is there in Drupal Community & their do's and don't's - Sivaji
Drupal Camp Delhi
 
Multi lingual implementations – drupal design approaches for different scenar...
Multi lingual implementations – drupal design approaches for different scenar...Multi lingual implementations – drupal design approaches for different scenar...
Multi lingual implementations – drupal design approaches for different scenar...
Drupal Camp Delhi
 
Integration of Drupal websites and Android applications - Girish Gupta
Integration of Drupal websites and Android applications - Girish GuptaIntegration of Drupal websites and Android applications - Girish Gupta
Integration of Drupal websites and Android applications - Girish Gupta
Drupal Camp Delhi
 
Graphics Designing (Character, Posters, Advertisements, Brochure, Interface B...
Graphics Designing (Character, Posters, Advertisements, Brochure, Interface B...Graphics Designing (Character, Posters, Advertisements, Brochure, Interface B...
Graphics Designing (Character, Posters, Advertisements, Brochure, Interface B...
Drupal Camp Delhi
 

Más de Drupal Camp Delhi (14)

Content Migration to Drupal 8
Content Migration to Drupal 8Content Migration to Drupal 8
Content Migration to Drupal 8
 
Drupal Camp Delhi 2015
Drupal Camp Delhi 2015Drupal Camp Delhi 2015
Drupal Camp Delhi 2015
 
Campusdiaries Showcase - Raj Chourasia
Campusdiaries Showcase - Raj ChourasiaCampusdiaries Showcase - Raj Chourasia
Campusdiaries Showcase - Raj Chourasia
 
Generics & Specifics of QA on Web - Sweta Shahi
Generics & Specifics of QA on Web - Sweta ShahiGenerics & Specifics of QA on Web - Sweta Shahi
Generics & Specifics of QA on Web - Sweta Shahi
 
Memcache and Drupal - Vaibhav Jain
Memcache and Drupal - Vaibhav JainMemcache and Drupal - Vaibhav Jain
Memcache and Drupal - Vaibhav Jain
 
How NOT to build Drupal Sites - Sai Tanay
How NOT to build Drupal Sites - Sai TanayHow NOT to build Drupal Sites - Sai Tanay
How NOT to build Drupal Sites - Sai Tanay
 
Amplify user engagement with Game Mechanics - Vidhatanand
Amplify user engagement with Game Mechanics - VidhatanandAmplify user engagement with Game Mechanics - Vidhatanand
Amplify user engagement with Game Mechanics - Vidhatanand
 
Future proof your drupal skills - Piyuesh Kumar
Future proof your drupal skills - Piyuesh KumarFuture proof your drupal skills - Piyuesh Kumar
Future proof your drupal skills - Piyuesh Kumar
 
Basic Responsive Theming - Somedutta Ghosh
Basic Responsive Theming - Somedutta GhoshBasic Responsive Theming - Somedutta Ghosh
Basic Responsive Theming - Somedutta Ghosh
 
What is there in Drupal Community & their do's and don't's - Sivaji
What is there in Drupal Community & their do's and don't's - SivajiWhat is there in Drupal Community & their do's and don't's - Sivaji
What is there in Drupal Community & their do's and don't's - Sivaji
 
Multi lingual implementations – drupal design approaches for different scenar...
Multi lingual implementations – drupal design approaches for different scenar...Multi lingual implementations – drupal design approaches for different scenar...
Multi lingual implementations – drupal design approaches for different scenar...
 
Integration of Drupal websites and Android applications - Girish Gupta
Integration of Drupal websites and Android applications - Girish GuptaIntegration of Drupal websites and Android applications - Girish Gupta
Integration of Drupal websites and Android applications - Girish Gupta
 
Graphics Designing (Character, Posters, Advertisements, Brochure, Interface B...
Graphics Designing (Character, Posters, Advertisements, Brochure, Interface B...Graphics Designing (Character, Posters, Advertisements, Brochure, Interface B...
Graphics Designing (Character, Posters, Advertisements, Brochure, Interface B...
 
Drupal Camp Delhi 2013 - Event Brochure
Drupal Camp Delhi 2013 -  Event BrochureDrupal Camp Delhi 2013 -  Event Brochure
Drupal Camp Delhi 2013 - Event Brochure
 

Último

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Último (20)

Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 

Drush to simplify Drupalers work - Sivaji

  • 1. Drush to simplify Drupalers work Sivaji J.G, KnackForge Soft Solutions Pvt. Ltd.
  • 2. About Speaker • • • • • • • • Started Drupal evangelism as trainee in 2008 Integrated Drupal and gnokii for accessing bus routes information via SMS GSoC Alumnus 2009 Co-maintainer of quiz module Contributor to Drupal Core and Contrib modules in drupal.org Technical reviewer of Drupal books Featured Speaker / Trainer of Drupal Chennai workshops Technical Director / Drupal project manager at KnackForge
  • 3. Agenda • • • • What is Drush? Requirements and Installation How it works? Drush commands
  • 4. What is Drush? • • • • • • Command line utility to administer Drupal sites Typically used as “drush [options] <command> [argument1] [argument2]” Commonly used for cache clear, managing modules / themes / features, cron, etc. Supports Drupal 6.x and above Works best on Unix like OS and partially supported for Windows Maintained in GitHub /drush-ops/drush
  • 5. Requirements and Installation • • From PEAR o https://github.com/drush-ops/drush#install---pear Manual Installation o https://github.com/drush-ops/drush#install---manual
  • 7. Drush Commands • • • • • • • • • pm-download site-install user-password variable-get / set cache-clear core-cron core-status php-script updatedb • • • • • • • • • watchdog-show pm-list pm-enable pm-disable pm-uninstall sql-drop sql-query sql-sync sql-connect
  • 8. $ drush pm-download (dl) • • • • • • Download any projects from drupal.org Project could Drupal core, modules, themes or profiles. Handles project dependency Sticks to recommended versions by default Automatically figure out which project version you want based Integrates with version control system (git, svn
  • 9. $ drush pm-download (dl) Usage $ drush dl Project drupal (7.23) downloaded to /home/sivaji/Public/drupal-7.23. [success] Project drupal contains: [success] - 3 profiles: standard, testing, minimal - 4 themes: bartik, garland, stark, seven - 47 modules: image, openid, simpletest,...
  • 10. $ drush pm-download (dl) $ drush dl views Project views (7.x-3.7) downloaded to /home/sivaji/Public/drupal-7.23/sites/all/modules/views. [success] $ drush dl zen $ drush dl features-7.x-2.x-dev
  • 11. $ drush site-install (si) Installs Drupal with specified install profile Usage $ drush si standard --site-name="Drush Test" --db-url=<mysql://root:pass@127.0.0.1/db More default values • • • o --account-mail, --account-name, --db-prefix, --locale, --site-mail, [form name].[parameter name]
  • 12. $ drush site-install (si) $ drush si standard --site-name="Drupal Camp" --dburl=mysql://root@127.0.0.1/learning_drush You are about to create a sites/default/files directory and create a sites/default/settings.php file and CREATE the 'learning_drush' database. Do you want to continue? (y/n): y Starting Drupal installation. This takes a few seconds ... [ok] Installation complete. User name: admin User password: AGn744iDVd
  • 13. $ drush user-password (upwd) (Re)Set the password for the user account with the specified name Usage: Changing the auto generated password AGn744iDVd to Admin!@# for admin user. $ drush upwd admin --password=Admin!@#
  • 14. $ drush variable-get / variable-set (vget/vset) Get a list of some or all site variables and values. Usage $ drush variable-get site_name site_name: "Drupal Camp" $ drush variable-set site_name "Drupal Camp Delhi"
  • 15. $ drush cache-clear (cc) Clear a specific cache, or all drupal caches Usage, $ drush cc all $ drush cc menu
  • 16. $ drush cache-clear (cc) $ drush cc Enter a number to choose which cache to clear. [0] : Cancel [1] : all [2] : drush [3] : theme-registry [4] : menu [5] : css-js [6] : block [7] : module-list [8] : theme-list [9] : registry [10] : token [11] : views