Hi,

I ran the status command on the latest dev version of Drush and I noticed that the database username wasn't displayed in the report. I had a look at the command help and saw the --show-passwords option, I used it but nothing happened.

I had a look at the code and found a typo in the field-labels array, the output processor tries to match db-user instead of db-username.
For the password information, the field is not defined and during the render of the output, keys without definition are not displayed.

Comments

Status:Active» Needs review
StatusFileSize
new2.51 KB

Here is a patch to fix this

Without the patch :

sudo drush -r ~/public_html/drupal7 status --show-passwords
Drupal version                  :  7.18-dev
Site URI                        :  http://default
Database driver                 :  mysql
Database name                   :  drupal7
Database                        :  Connected
Drupal bootstrap                :  Successful
Drupal user                     :  Anonymous
Default theme                   :  bartik
Administration theme            :  seven
PHP configuration               :  /etc/php5/cli/php.ini
Drush version                   :  6.0-dev
Drush configuration             :
Drush alias files               :
Drupal root                     :  /home/vagrant/public_html/drupal7
Site path                       :  sites/default
File directory path             :  sites/default/files
Temporary file directory path   :  /tmp

With the patch :

$ drush -r ~/public_html/drupal7 status --show-passwords
Drupal version                  :  7.18-dev
Site URI                        :  http://default
Database driver                 :  mysql
Database username               :  root
Database password               :  password
Database name                   :  drupal7
Database                        :  Connected
Drupal bootstrap                :  Successful
Drupal user                     :  Anonymous
Default theme                   :  bartik
Administration theme            :  seven
PHP configuration               :  /etc/php5/cli/php.ini
Drush version                   :  6.0-dev
Drush configuration             :
Drush alias files               :
Drupal root                     :  /home/vagrant/public_html/drupal7
Site path                       :  sites/default
File directory path             :  sites/default/files
Temporary file directory path   :  /tmp

Status:Needs review» Fixed

Committed. Thanks.

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.