Browse Source

Added ee site update example.com --password

bugfixes
Mitesh Shah 10 years ago
parent
commit
6dd37a323e
  1. 5
      bin/easyengine
  2. 10
      src/modules/site/update/ee_mod_site_update_password.sh

5
bin/easyengine

@ -648,8 +648,11 @@ elif [ "$EE_FIRST" = "site" ]; then
# Let's log site current option
ee_lib_echo_escape "EE_SITE_CURRENT_WP = $EE_SITE_CURRENT_WP \nEE_SITE_CURRENT_CACHE = $EE_SITE_CURRENT_CACHE \nEE_SITE_CURRENT_TYPE = $EE_SITE_CURRENT_TYPE \nEE_SITE_UPDATE_TYPE = $EE_SITE_UPDATE_TYPE" &>> $EE_COMMAND_LOG
# Update WordPress user password
if [ "$EE_SITE_CREATE_OPTION" = "--password" ]; then
ee_mod_site_update_password
# Lets update HTML|PHP website
if [[ "$EE_SITE_CURRENT_TYPE" = "--html" && "$EE_SITE_CREATE_OPTION" != "--html" ]] || [[ "$EE_SITE_CURRENT_TYPE" = "--php" && "$EE_SITE_CREATE_OPTION" != "--html" && "$EE_SITE_CREATE_OPTION" != "--php" ]]; then
elif [[ "$EE_SITE_CURRENT_TYPE" = "--html" && "$EE_SITE_CREATE_OPTION" != "--html" ]] || [[ "$EE_SITE_CURRENT_TYPE" = "--php" && "$EE_SITE_CREATE_OPTION" != "--html" && "$EE_SITE_CREATE_OPTION" != "--php" ]]; then
# Lets call update function
ee_mod_update_website

10
src/modules/site/update/ee_mod_site_update_password.sh

@ -12,7 +12,15 @@ ee_mod_site_update_password()
if [ $? -eq 0 ]; then
read -p "Provide WordPress user name [admin]: " ee_wp_user
if [[ $ee_wp_user = "" ]]; then
# If user enter ? mark then show list of WordPress users
if [ "$ee_wp_user" = "?" ]; then
ee_lib_echo "List of WordPress users:"
wp --allow-root user list --fields=user_login
read -p "Provide WordPress user name [admin]: " ee_wp_user
fi
if [ "$ee_wp_user" = "" ]; then
ee_wp_user=admin
fi

Loading…
Cancel
Save