ML
    • Recent
    • Categories
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    WP-CLI: Command line interface for WordPress

    IT Discussion
    6
    20
    1.9k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • ?
      A Former User
      last edited by

      http://wp-cli.org/

      I have been using this for a while now, and I love it. Basically you can control WordPress right from the CL. Awesome stuff.

      1 Reply Last reply Reply Quote 4
      • nadnerBN
        nadnerB
        last edited by

        Everything seems to work better when you can use the command line to... BASH it into submission

        1 Reply Last reply Reply Quote 2
        • thanksajdotcomT
          thanksajdotcom
          last edited by

          I posted this awhile ago!

          I have a script I wrote that automatically updates my Wordpress sites every 3 hours via cron...

          ==================================================================================
          #!/bin/sh
          echo

          echo The current time and date is: $(date)

          echo

          cd /var/www/builtbyart.com
          pwd | ts
          /usr/local/bin/wp core update --allow-root | ts
          /usr/local/bin/wp theme update --all --allow-root | ts
          /usr/local/bin/wp plugin update --all --allow-root | ts
          /usr/local/bin/wp comment delete $(/usr/local/bin/wp comment list --status=spam --format=ids --allow-root) --allow-root | ts

          echo

          cd /var/www/literaryworksbyaj.com
          pwd | ts
          /usr/local/bin/wp core update --allow-root | ts
          /usr/local/bin/wp theme update --all --allow-root | ts
          /usr/local/bin/wp plugin update --all --allow-root | ts
          /usr/local/bin/wp comment delete $(/usr/local/bin/wp comment list --status=spam --format=ids --allow-root) --allow-root | ts

          echo

          cd /var/www/thanksaj.com
          pwd | ts
          /usr/local/bin/wp core update --allow-root | ts
          /usr/local/bin/wp theme update --all --allow-root | ts
          /usr/local/bin/wp plugin update --all --allow-root | ts
          /usr/local/bin/wp comment delete $(/usr/local/bin/wp comment list --status=spam --format=ids --allow-root) --allow-root | ts

          To use ts, you use

          apt-get -y install moreutils
          
          1 Reply Last reply Reply Quote 0
          • thanksajdotcomT
            thanksajdotcom
            last edited by

            I point to the full path because sometimes, via script, it didn't work without it.

            1 Reply Last reply Reply Quote 0
            • tonyshowoffT
              tonyshowoff
              last edited by

              May God have mercy on us all...

              thanksajdotcomT 1 Reply Last reply Reply Quote 0
              • thanksajdotcomT
                thanksajdotcom @tonyshowoff
                last edited by

                @tonyshowoff said:

                May God have mercy on us all...

                For what? ROFL

                tonyshowoffT 1 Reply Last reply Reply Quote 0
                • tonyshowoffT
                  tonyshowoff @thanksajdotcom
                  last edited by

                  @thanksajdotcom said:

                  @tonyshowoff said:

                  May God have mercy on us all...

                  For what? ROFL

                  WordPress is the WIndows 95 of blogging software, and now it's invaded command line, there's no escape from the clutches of one of the worst code bases to ever exist.

                  thanksajdotcomT 1 Reply Last reply Reply Quote -1
                  • thanksajdotcomT
                    thanksajdotcom @tonyshowoff
                    last edited by

                    @tonyshowoff said:

                    @thanksajdotcom said:

                    @tonyshowoff said:

                    May God have mercy on us all...

                    For what? ROFL

                    WordPress is the WIndows 95 of blogging software, and now it's invaded command line, there's no escape from the clutches of one of the worst code bases to ever exist.

                    Wordpress is great! What you smokin'? 😛

                    tonyshowoffT 1 Reply Last reply Reply Quote 0
                    • tonyshowoffT
                      tonyshowoff @thanksajdotcom
                      last edited by

                      @thanksajdotcom said:

                      @tonyshowoff said:

                      @thanksajdotcom said:

                      @tonyshowoff said:

                      May God have mercy on us all...

                      For what? ROFL

                      WordPress is the WIndows 95 of blogging software, and now it's invaded command line, there's no escape from the clutches of one of the worst code bases to ever exist.

                      Wordpress is great! What you smokin'? 😛

                      The slowest, worst written blogging system in existence is great? Well, I guess some people enjoy herpes too. 😛

                      nadnerBN scottalanmillerS 2 Replies Last reply Reply Quote 0
                      • nadnerBN
                        nadnerB @tonyshowoff
                        last edited by

                        @tonyshowoff said:

                        The slowest, worst written blogging system in existence is great? Well, I guess some people enjoy herpes too. 😛

                        lol, bad experience(s), eh?
                        Out of genuine interest, what's your favourite?

                        tonyshowoffT 1 Reply Last reply Reply Quote 0
                        • scottalanmillerS
                          scottalanmiller @tonyshowoff
                          last edited by

                          @tonyshowoff said:

                          @thanksajdotcom said:

                          @tonyshowoff said:

                          @thanksajdotcom said:

                          @tonyshowoff said:

                          May God have mercy on us all...

                          For what? ROFL

                          WordPress is the WIndows 95 of blogging software, and now it's invaded command line, there's no escape from the clutches of one of the worst code bases to ever exist.

                          Wordpress is great! What you smokin'? 😛

                          The slowest, worst written blogging system in existence is great? Well, I guess some people enjoy herpes too. 😛

                          You use Ghost?

                          tonyshowoffT 1 Reply Last reply Reply Quote 0
                          • tonyshowoffT
                            tonyshowoff @nadnerB
                            last edited by

                            @nadnerB said:

                            @tonyshowoff said:

                            The slowest, worst written blogging system in existence is great? Well, I guess some people enjoy herpes too. 😛

                            lol, bad experience(s), eh?
                            Out of genuine interest, what's your favourite?

                            Bad experience? I developed on the WordPress code base in the past, it literally is one of the worst code bases there is. It's extremely disorganised, doesn't properly meet any standard in existence, and even today the code is approached as if it's written in PHP 4.1. WordPress has more vulnerabilities than almost any other equally popular piece of software, and also their crappy API leads to crappy plugins which also have tons of vulnerabilities. The key people in WordPress don't know how to program, that's the primary issue.

                            I don't have a favourite, they're all shit, and ironically WordPress is the best because it's easiest to get going and has so many options available. It's poorly executed. Turn on query log sometime, a regular page load will probably be about 100 database queries, many of them identical, which screams incompetence. It's sort of funny, WordPress attempts to promote caching tools for problems they themselves have created.

                            Here's some more detail:

                            http://community.spiceworks.com/topic/post/4257928

                            nadnerBN 1 Reply Last reply Reply Quote 0
                            • tonyshowoffT
                              tonyshowoff @scottalanmiller
                              last edited by tonyshowoff

                              @scottalanmiller said:

                              @tonyshowoff said:

                              @thanksajdotcom said:

                              @tonyshowoff said:

                              @thanksajdotcom said:

                              @tonyshowoff said:

                              May God have mercy on us all...

                              For what? ROFL

                              WordPress is the WIndows 95 of blogging software, and now it's invaded command line, there's no escape from the clutches of one of the worst code bases to ever exist.

                              Wordpress is great! What you smokin'? 😛

                              The slowest, worst written blogging system in existence is great? Well, I guess some people enjoy herpes too. 😛

                              You use Ghost?

                              Oh please, everything Symantec makes is amazingly great and competent, I'm 100% sure their programmers don't have severe brain damage.

                              scottalanmillerS 1 Reply Last reply Reply Quote 0
                              • scottalanmillerS
                                scottalanmiller @tonyshowoff
                                last edited by

                                @tonyshowoff said:

                                Oh please, everything Symantec makes is amazingly great and competent, I'm 100% sure their programmers don't have severe brain damage.

                                https://ghost.org/

                                Ghost the blogging platform.

                                tonyshowoffT 1 Reply Last reply Reply Quote 0
                                • tonyshowoffT
                                  tonyshowoff @scottalanmiller
                                  last edited by

                                  @scottalanmiller said:

                                  @tonyshowoff said:

                                  Oh please, everything Symantec makes is amazingly great and competent, I'm 100% sure their programmers don't have severe brain damage.

                                  https://ghost.org/

                                  Ghost the blogging platform.

                                  I figured that's what you meant, and no I haven't, but I couldn't resist the opportunity to trash Symantec.

                                  ? 1 Reply Last reply Reply Quote 2
                                  • ?
                                    A Former User @tonyshowoff
                                    last edited by

                                    @tonyshowoff said:

                                    @scottalanmiller said:

                                    @tonyshowoff said:

                                    Oh please, everything Symantec makes is amazingly great and competent, I'm 100% sure their programmers don't have severe brain damage.

                                    https://ghost.org/

                                    Ghost the blogging platform.

                                    I figured that's what you meant, and no I haven't, but I couldn't resist the opportunity to trash Symantec.

                                    You don't have too, they already trashed themselves.

                                    1 Reply Last reply Reply Quote 0
                                    • nadnerBN
                                      nadnerB @tonyshowoff
                                      last edited by

                                      @tonyshowoff said:

                                      @nadnerB said:

                                      @tonyshowoff said:

                                      The slowest, worst written blogging system in existence is great? Well, I guess some people enjoy herpes too. 😛

                                      lol, bad experience(s), eh?
                                      Out of genuine interest, what's your favourite?

                                      Bad experience? I developed on the WordPress code base in the past, it literally is one of the worst code bases there is. It's extremely disorganised, doesn't properly meet any standard in existence, and even today the code is approached as if it's written in PHP 4.1. WordPress has more vulnerabilities than almost any other equally popular piece of software, and also their crappy API leads to crappy plugins which also have tons of vulnerabilities. The key people in WordPress don't know how to program, that's the primary issue.

                                      I don't have a favourite, they're all shit, and ironically WordPress is the best because it's easiest to get going and has so many options available. It's poorly executed. Turn on query log sometime, a regular page load will probably be about 100 database queries, many of them identical, which screams incompetence. It's sort of funny, WordPress attempts to promote caching tools for problems they themselves have created.

                                      Here's some more detail:

                                      http://community.spiceworks.com/topic/post/4257928

                                      Righto, well that's a good read 🙂
                                      I would imagine a lot of things are just as messed up

                                      tonyshowoffT 1 Reply Last reply Reply Quote 0
                                      • tonyshowoffT
                                        tonyshowoff @nadnerB
                                        last edited by

                                        @nadnerB said:

                                        @tonyshowoff said:

                                        @nadnerB said:

                                        @tonyshowoff said:

                                        The slowest, worst written blogging system in existence is great? Well, I guess some people enjoy herpes too. 😛

                                        lol, bad experience(s), eh?
                                        Out of genuine interest, what's your favourite?

                                        Bad experience? I developed on the WordPress code base in the past, it literally is one of the worst code bases there is. It's extremely disorganised, doesn't properly meet any standard in existence, and even today the code is approached as if it's written in PHP 4.1. WordPress has more vulnerabilities than almost any other equally popular piece of software, and also their crappy API leads to crappy plugins which also have tons of vulnerabilities. The key people in WordPress don't know how to program, that's the primary issue.

                                        I don't have a favourite, they're all shit, and ironically WordPress is the best because it's easiest to get going and has so many options available. It's poorly executed. Turn on query log sometime, a regular page load will probably be about 100 database queries, many of them identical, which screams incompetence. It's sort of funny, WordPress attempts to promote caching tools for problems they themselves have created.

                                        Here's some more detail:

                                        http://community.spiceworks.com/topic/post/4257928

                                        Righto, well that's a good read 🙂
                                        I would imagine a lot of things are just as messed up

                                        All you have to do with a crappy piece of software is add a bunch of themes and then people will accept it.

                                        ? 1 Reply Last reply Reply Quote 1
                                        • ?
                                          A Former User @tonyshowoff
                                          last edited by A Former User

                                          @tonyshowoff said:

                                          @nadnerB said:

                                          @tonyshowoff said:

                                          @nadnerB said:

                                          @tonyshowoff said:

                                          The slowest, worst written blogging system in existence is great? Well, I guess some people enjoy herpes too. 😛

                                          lol, bad experience(s), eh?
                                          Out of genuine interest, what's your favourite?

                                          Bad experience? I developed on the WordPress code base in the past, it literally is one of the worst code bases there is. It's extremely disorganised, doesn't properly meet any standard in existence, and even today the code is approached as if it's written in PHP 4.1. WordPress has more vulnerabilities than almost any other equally popular piece of software, and also their crappy API leads to crappy plugins which also have tons of vulnerabilities. The key people in WordPress don't know how to program, that's the primary issue.

                                          I don't have a favourite, they're all shit, and ironically WordPress is the best because it's easiest to get going and has so many options available. It's poorly executed. Turn on query log sometime, a regular page load will probably be about 100 database queries, many of them identical, which screams incompetence. It's sort of funny, WordPress attempts to promote caching tools for problems they themselves have created.

                                          Here's some more detail:

                                          http://community.spiceworks.com/topic/post/4257928

                                          Righto, well that's a good read 🙂
                                          I would imagine a lot of things are just as messed up

                                          All you have to do with a crappy piece of software is add a bunch of themes and then people will accept it.

                                          Wait where you talking about wordpress or windows? 🙂

                                          tonyshowoffT 1 Reply Last reply Reply Quote 2
                                          • tonyshowoffT
                                            tonyshowoff @A Former User
                                            last edited by

                                            @thecreativeone91 said:

                                            @tonyshowoff said:

                                            @nadnerB said:

                                            @tonyshowoff said:

                                            @nadnerB said:

                                            @tonyshowoff said:

                                            The slowest, worst written blogging system in existence is great? Well, I guess some people enjoy herpes too. 😛

                                            lol, bad experience(s), eh?
                                            Out of genuine interest, what's your favourite?

                                            Bad experience? I developed on the WordPress code base in the past, it literally is one of the worst code bases there is. It's extremely disorganised, doesn't properly meet any standard in existence, and even today the code is approached as if it's written in PHP 4.1. WordPress has more vulnerabilities than almost any other equally popular piece of software, and also their crappy API leads to crappy plugins which also have tons of vulnerabilities. The key people in WordPress don't know how to program, that's the primary issue.

                                            I don't have a favourite, they're all shit, and ironically WordPress is the best because it's easiest to get going and has so many options available. It's poorly executed. Turn on query log sometime, a regular page load will probably be about 100 database queries, many of them identical, which screams incompetence. It's sort of funny, WordPress attempts to promote caching tools for problems they themselves have created.

                                            Here's some more detail:

                                            http://community.spiceworks.com/topic/post/4257928

                                            Righto, well that's a good read 🙂
                                            I would imagine a lot of things are just as messed up

                                            All you have to do with a crappy piece of software is add a bunch of themes and then people will accept it.

                                            Wait where you talking about wordpress or windows? 🙂

                                            Yes

                                            1 Reply Last reply Reply Quote 1
                                            • 1 / 1
                                            • First post
                                              Last post