CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Discussion (deprecated) »
  • Feature Requests and Suggestions (Moderator: Dave Greenberg) »
  • drush and civicrm
Pages: [1]

Author Topic: drush and civicrm  (Read 2416 times)

guaka

  • I’m new here
  • *
  • Posts: 29
  • Karma: 1
    • my blog
drush and civicrm
February 10, 2010, 05:55:55 pm
I started hacking on some drushy stuff, first with the API but then I decided to first do something like "drush cache clear" for CiviCRM in the hope to shorten long lists of steps to check while migrating CiviCRM - http://wiki.civicrm.org/confluence/display/CRMDOC/Moving+an+Existing+Installation+to+a+New+Server+or+Location

See http://wiki.civicrm.org/confluence/display/CRMDOC/Drush+CiviCRM+proof+of+concept

It's probably already useful as it is.  Please let me know if there's more stuff that can be cleared.

guaka

  • I’m new here
  • *
  • Posts: 29
  • Karma: 1
    • my blog
Re: drush and civicrm
February 10, 2010, 06:20:47 pm
I kinda hooked REST.php into it now.  It looks clean but there's a problem with this part

            if ( ! file_exists( $apiPath . $apiFile ) ) {
                           return self::error( 'Unknown function invocation.' ); 
            }

Simply uncommenting this makes it work fine for now but it would probably be good to put something smarter instead of $apiPath = substr( $_SERVER['SCRIPT_FILENAME'] , 0 ,-15 );
Any ideas?

FatherShawn

  • Ask me questions
  • ****
  • Posts: 372
  • Karma: 25
    • C3 Design
  • CiviCRM version: 4.2.11
  • CMS version: Drupal 7.23
  • MySQL version: 5.5.32
  • PHP version: 5.3.10
Re: drush and civicrm
November 19, 2010, 05:23:27 am
I just want to say thank you for the civicrm drush commands!  I've had them installed for a while but hadn't done much with them.  I just decided to give the upgrade command a spin - awesome!!

Code: [Select]
$ drush civicrm-upgrade --tarfile=/Users/shawn/Downloads/civicrm-3.2.5-drupal.tar.gz

The upgrade process involves -
1. Backing up current CiviCRM code as => /path/to/drupal/root/../backup/modules/20101118221508/civicrm
2. Backing up database as => /path/to/drupal/root/../backup/modules/20101118221508/civicrm.sql
3. Unpacking tarfile to => /path/to/drupal/root//sites/all/modules/
4. Executing civicrm/upgrade?reset=1 just as a browser would.

Do you really want to continue? (y/n): y
                                                                                                              [ok]
1. Code backed up.
2. Database backed up.                                                                                        [ok]
3. Tarfile unpacked.                                                                                          [ok]
4.
Starting with v3.2.1 -> v3.2.5 upgrade ..
Upgrade outputs: "CiviCRM upgrade was successful."
                                                                                                              [completed]
Process completed.

Easiest civi upgrade ever!!
Lead Developer, C3 Design.
Twitter: @FatherShawn

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Discussion (deprecated) »
  • Feature Requests and Suggestions (Moderator: Dave Greenberg) »
  • drush and civicrm

This forum was archived on 2017-11-26.