{"id":1683,"date":"2018-01-03T15:30:59","date_gmt":"2018-01-03T20:30:59","guid":{"rendered":"http:\/\/mossiso.com\/?p=1683"},"modified":"2018-01-03T15:30:59","modified_gmt":"2018-01-03T20:30:59","slug":"quick-wp-upgrading-with-wpcli","status":"publish","type":"post","link":"https:\/\/mossiso.com\/2018\/01\/03\/quick-wp-upgrading-with-wpcli\/","title":{"rendered":"Quick WP upgrading with WPCLI"},"content":{"rendered":"<p>This is the easiest way to upgrade WordPress. You&#8217;ll execute these commands on the server itself.<\/p>\n<h1>Requirements<\/h1>\n<ul>\n<li>ssh access to your server<\/li>\n<li>wp-cli command installed (instructions for installing wp-cli at <a href=\"http:\/\/wp-cli.org\/\">http:\/\/wp-cli.org\/<\/a>)<\/li>\n<\/ul>\n<h2>Install\/Upgrade WP CLI<\/h2>\n<ul>\n<li><strong>wp-cli should be upgraded each time a WordPress installation is upgraded.<\/strong><\/li>\n<\/ul>\n<pre><code>wp cli update\n<\/code><\/pre>\n<h2>Upgrade WP<\/h2>\n<h3>Prep work<\/h3>\n<p>Change into the WP directory<\/p>\n<pre><code>cd \/path\/to\/wordpress\/installation\/\n<\/code><\/pre>\n<p>Make a list of active plugins<\/p>\n<pre><code>wp plugin list --status=active --format=csv --fields=name | tail -n +2 &gt; ..\/active-plugins.txt\n<\/code><\/pre>\n<h3>Update all plugins<\/h3>\n<pre><code>wp plugin update --all\n<\/code><\/pre>\n<h3>Deactivate all of the plugins<\/h3>\n<pre><code>wp plugin deactivate --all\n<\/code><\/pre>\n<h3>Upgrade WordPress<\/h3>\n<pre><code>wp core update\n<\/code><\/pre>\n<h3>Reactivate all of the previously active plugins.<\/h3>\n<pre><code>cat ..\/active-plugins.txt | xargs wp plugin activate\n<\/code><\/pre>\n<h1>Check the site in various browsers (make sure cache has been cleared).<\/h1>\n","protected":false},"excerpt":{"rendered":"<p>This is the easiest way to upgrade WordPress. You&#8217;ll execute these commands on the server itself. Requirements ssh access to your server wp-cli command installed (instructions for installing wp-cli at http:\/\/wp-cli.org\/) Install\/Upgrade WP CLI wp-cli should be upgraded each time a WordPress installation is upgraded. wp cli update Upgrade WP Prep work Change into the &hellip; <a href=\"https:\/\/mossiso.com\/2018\/01\/03\/quick-wp-upgrading-with-wpcli\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Quick WP upgrading with WPCLI<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"aside","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[243,259,167,9,10],"tags":[293,278],"class_list":["post-1683","post","type-post","status-publish","format-aside","hentry","category-howto","category-systems-administration-technical","category-technical","category-technology","category-wordpress","tag-update-wp","tag-wordpress","post_format-post-format-aside"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p9wosP-r9","_links":{"self":[{"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/posts\/1683"}],"collection":[{"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/comments?post=1683"}],"version-history":[{"count":5,"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/posts\/1683\/revisions"}],"predecessor-version":[{"id":1690,"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/posts\/1683\/revisions\/1690"}],"wp:attachment":[{"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/media?parent=1683"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/categories?post=1683"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mossiso.com\/wp-json\/wp\/v2\/tags?post=1683"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}