Created
January 30, 2018 21:31
-
-
Save calvez/34bb3704b6949c9585cf554d813969ad to your computer and use it in GitHub Desktop.
/usr/local/bin/wpup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
timestamp1=$(date "+%Y%m%d-%H%M%S") | |
RED=`tput setaf 1` | |
GREEN=`tput setaf 2` | |
NC=`tput sgr0` | |
echo "Database backup" | |
wp db export | |
echo -e "${RED}Update Wordpress core...${NC}\n" | |
wp core update | |
echo -e "${GREEN}Wordpress core updated!${NC}\n" | |
echo -e "${RED}Update Wordpress plugins...${NC}\n" | |
wp plugin update --all | |
echo -e "${GREEN}Wordpress plugins updated!${NC}\n" | |
echo -e "${RED}Update Wordpress themes...${NC}\n" | |
wp theme update --all | |
echo -e "${GREEN}Wordpress themes updated!${NC}\n" | |
echo -e "${RED}Update Wordpress core languages...${NC}\n" | |
wp core language update | |
echo -e "${GREEN}Wordpress core languages updated!${NC}\n" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment