0

What to do when I want specific dev version of Drupal module.

For example:

Geocoder dev version from Jan 07 2016 is broken. Latest working dev version was from Sept 01 2015.

How can I download previous dev version of Drupal module (Geocoder in my case)? Any method is welcome.

2
  • Why do you need to do it via Drush? Is it just a case or is it really important?
    – Eugene
    Commented Jan 10, 2016 at 7:22
  • @Eugene Any method welcome (I have updated my question). Commented Jan 10, 2016 at 7:26

2 Answers 2

4

For the easiest way to do it:

  1. Go into the repository
  2. Select a version there and click on it
  3. There will be hash of commit (example)

So, you know the hash of commit - just clone this module from repository and switch to required hash of commit.

How to clone module via git

How to checkout the specific commit

Example:

git clone --branch 7.x-1.x https://git.drupal.org/project/geocoder.git
cd geocoder
git checkout c994066d58bc7518bc9796c60d4d43f98ae477cd
0
1

I want to add one more way how to download specific dev version of Drupal module:

“Drush make” method

Create make file for Drush (for example myMakeFile.make) and paste into it following:

api = 2
core = 7.x
projects[drupal][version] = 7.30
projects[geocoder][version] = "1.x-dev"
projects[geocoder][download][type] = "git"
projects[geocoder][download][url] = "https://git.drupal.org/project/geocoder.git"
projects[geocoder][download][revision] = "2ffd3fa8b22c11100516bf801bc08ba729cc8a68"

Type into shell:

cd
mkdir removeMeWhenDone
mv myMakeFile.make removeMeWhenDone
cd removeMeWhenDone
drush make myMakeFile.make -y

Desired dev version of the Geocoder module is located in ~/removeMeWhenDone/sites/all/modules, now.

More details about Drush make method + how to get commit hash here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.